Skip to content

Commit

Permalink
Merge pull request #205 from matomo-org/php8build
Browse files Browse the repository at this point in the history
Added additional build for php8
  • Loading branch information
AltamashShaikh authored Nov 3, 2021
2 parents f653e50 + 50583b5 commit c8b9e1b
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 deletions.
10 changes: 10 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,16 @@ matrix:
# execute UI tests only w/ PHP 5.6
- php: 7.4
env: TEST_SUITE=UITests MYSQL_ADAPTER=PDO_MYSQL TEST_AGAINST_PIWIK_BRANCH=$PIWIK_TEST_TARGET
include:
- php: 8.0
env: TEST_SUITE=PluginTests MYSQL_ADAPTER=PDO_MYSQL TEST_AGAINST_PIWIK_BRANCH=$PIWIK_TEST_TARGET SKIP_COMPOSER_INSTALL=1
script:
- cd $PIWIK_ROOT_DIR
- composer install --ignore-platform-reqs
- composer remove --dev phpunit/phpunit
- composer require --dev phpunit/phpunit ~9.3 --ignore-platform-reqs
- cd tests/PHPUnit
- $PIWIK_ROOT_DIR/tests/travis/travis.sh

dist: bionic

Expand Down
2 changes: 1 addition & 1 deletion ImportStatus.php
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ public function getAllImportStatuses($checkKilledStatus = false)
$result[] = $status;
}

usort($result, function (&$lhs, $rhs) {
usort($result, function ($lhs, $rhs) {
$lhsIdSite = (int)($lhs['idSite'] ?? 0);
$rhsIdSite = (int)($rhs['idSite'] ?? 0);

Expand Down
1 change: 1 addition & 0 deletions TESTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Before running, the following environment variables must be set:
```
$ export PIWIK_TEST_GA_VIEW_ID=2352671
$ export GA_PROPERTY_ID=UA-95026-4
$ export MATOMO_USE_MOCK_RESPONSE=1
```

You must also provide credentials to the test GA site in some way. There are two ways to do this:
Expand Down
2 changes: 1 addition & 1 deletion tests/Fixtures/ImportedFromGoogle.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public function setUp(): void
$this->scheduleReimport($idSite = 1, '2019-06-27', '2019-06-27');

$output = $this->runGoogleImporter($this->importedDateRange2, $idSite = 1);
$this->assertContains('Importing reports for date range 2019-06-27 - 2019-06-27 from GA view', $output);
$this->assertStringContainsString('Importing reports for date range 2019-06-27 - 2019-06-27 from GA view', $output);

$this->runGoogleImporter($this->campaignDataDateRange);

Expand Down

0 comments on commit c8b9e1b

Please sign in to comment.