public function PageviewTest::testWithFieldsObjectSettingCommmands in Googalytics - Google Analytics 8
Test the command array when values are provided in fieldsObject.
File
- tests/
src/ Unit/ AnalyticsCommand/ PageviewTest.php, line 35
Class
- PageviewTest
- @coversDefaultClass \Drupal\ga\AnalyticsCommand\Pageview @group ga
Namespace
Drupal\Tests\ga\Unit\AnalyticsCommandCode
public function testWithFieldsObjectSettingCommmands() {
$command = new Pageview([
'field1' => 'value1',
]);
$this
->assertEquals([
[
'send',
'pageview',
[
'field1' => 'value1',
],
],
], $command
->getSettingCommands());
}