Skip to content

Commit 348af14

Browse files
committed
remove GA4 tests
1 parent 49eea8c commit 348af14

5 files changed

Lines changed: 0 additions & 251 deletions

File tree

phpstan-baseline.neon

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -840,11 +840,6 @@ parameters:
840840
count: 1
841841
path: tests/Keboola/GoogleAnalyticsExtractor/ApplicationTest.php
842842

843-
-
844-
message: "#^Method Keboola\\\\GoogleAnalyticsExtractor\\\\ApplicationTest\\:\\:assertManifestContainsColumns\\(\\) has parameter \\$expected with no value type specified in iterable type array\\.$#"
845-
count: 1
846-
path: tests/Keboola/GoogleAnalyticsExtractor/ApplicationTest.php
847-
848843
-
849844
message: "#^Method Keboola\\\\GoogleAnalyticsExtractor\\\\ApplicationTest\\:\\:getConfig\\(\\) return type has no value type specified in iterable type array\\.$#"
850845
count: 1
@@ -855,11 +850,6 @@ parameters:
855850
count: 1
856851
path: tests/Keboola/GoogleAnalyticsExtractor/ApplicationTest.php
857852

858-
-
859-
message: "#^Parameter \\#1 \\$json of function json_decode expects string, string\\|false given\\.$#"
860-
count: 1
861-
path: tests/Keboola/GoogleAnalyticsExtractor/ApplicationTest.php
862-
863853
-
864854
message: "#^Parameter \\#2 \\$array of static method PHPUnit\\\\Framework\\\\Assert\\:\\:assertArrayHasKey\\(\\) expects array\\|ArrayAccess, mixed given\\.$#"
865855
count: 2

tests/Keboola/GoogleAnalyticsExtractor/ApplicationTest.php

Lines changed: 0 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -50,72 +50,6 @@ private function getConfig(string $suffix = ''): array
5050
return $config;
5151
}
5252

53-
public function testAppRunDailyWalk(): void
54-
{
55-
$this->config = $this->getConfig('_antisampling');
56-
$this->runProcess();
57-
58-
$dailyWalk = $this->getManifestFiles('dailyWalk');
59-
Assert::assertEquals(1, count($dailyWalk));
60-
61-
foreach ($dailyWalk as $file) {
62-
/** @var $file SplFileInfo */
63-
$this->assertManifestContainsColumns($file->getPathname(), [
64-
'id',
65-
'idProfile',
66-
'date',
67-
'sourceMedium',
68-
'landingPagePath',
69-
'pageviews',
70-
]);
71-
}
72-
}
73-
74-
public function testAppRunAdaptive(): void
75-
{
76-
$this->config = $this->getConfig('_antisampling_adaptive');
77-
$this->runProcess();
78-
79-
$adaptive = $this->getManifestFiles('adaptive');
80-
Assert::assertEquals(1, count($adaptive));
81-
82-
foreach ($adaptive as $file) {
83-
/** @var $file SplFileInfo */
84-
$this->assertManifestContainsColumns($file->getPathname(), [
85-
'id',
86-
'idProfile',
87-
'date',
88-
'sourceMedium',
89-
'landingPagePath',
90-
'pageviews',
91-
]);
92-
}
93-
}
94-
95-
public function testAppRunMCF(): void
96-
{
97-
$this->config = $this->getConfig('_mcf');
98-
$this->runProcess();
99-
100-
$funnelFiles = $this->getManifestFiles('funnel');
101-
Assert::assertEquals(1, count($funnelFiles));
102-
103-
foreach ($funnelFiles as $file) {
104-
/** @var $file SplFileInfo */
105-
$this->assertManifestContainsColumns($file->getPathname(), [
106-
'id',
107-
'idProfile',
108-
'mcf:conversionDate',
109-
'mcf:sourcePath',
110-
'mcf:mediumPath',
111-
'mcf:sourceMedium',
112-
'mcf:totalConversions',
113-
'mcf:totalConversionValue',
114-
'mcf:assistedConversions',
115-
]);
116-
}
117-
}
118-
11953
public function testAppProfilesProperties(): void
12054
{
12155
$this->config = $this->getConfig('_empty');
@@ -183,13 +117,6 @@ private function getManifestFiles(string $queryName): Finder
183117
;
184118
}
185119

186-
private function assertManifestContainsColumns(string $pathname, array $expected): void
187-
{
188-
$manifest = (array) json_decode(file_get_contents($pathname), true, 512, JSON_THROW_ON_ERROR);
189-
Assert::assertArrayHasKey('columns', $manifest);
190-
Assert::assertEquals($expected, $manifest['columns']);
191-
}
192-
193120
public function appRunDataProvider(): Generator
194121
{
195122
yield 'configRow' => [

tests/data/config_antisampling.json

Lines changed: 0 additions & 52 deletions
This file was deleted.

tests/data/config_antisampling_adaptive.json

Lines changed: 0 additions & 53 deletions
This file was deleted.

tests/data/config_mcf.json

Lines changed: 0 additions & 63 deletions
This file was deleted.

0 commit comments

Comments
 (0)