diff options
author | Thomas Steur <tsteur@users.noreply.github.com> | 2020-10-01 23:12:31 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-01 23:12:31 +0300 |
commit | 82186597b37e255a5b13f6b9c7e53d323b2c501b (patch) | |
tree | 5f30ed30c5cd63d6451280e7a6b8081245be6316 /tests | |
parent | 13cda22af49f616d1e5967364a041215f864d0c5 (diff) |
Rename login_whitelist_ip config to login_allowlist_ip (#16413)
Diffstat (limited to 'tests')
4 files changed, 15 insertions, 14 deletions
diff --git a/tests/PHPUnit/Integration/CronArchiveTest.php b/tests/PHPUnit/Integration/CronArchiveTest.php index beb920193e..8b2e3a05d5 100644 --- a/tests/PHPUnit/Integration/CronArchiveTest.php +++ b/tests/PHPUnit/Integration/CronArchiveTest.php @@ -419,10 +419,11 @@ Total API requests: 5 done: 5 req, %d ms, no error Time elapsed: %fs LOG; + $version = Version::VERSION; $expected = <<<LOG --------------------------- INIT -Running Matomo 4.0.0-b2 as Super User +Running Matomo $version as Super User --------------------------- NOTES - If you execute this script at least once per hour (or more often) in a crontab, you may disable 'Browser trigger archiving' in Matomo UI > Settings > General Settings. diff --git a/tests/PHPUnit/Integration/ReleaseCheckListTest.php b/tests/PHPUnit/Integration/ReleaseCheckListTest.php index cf0214b2e9..2f7b258b6d 100644 --- a/tests/PHPUnit/Integration/ReleaseCheckListTest.php +++ b/tests/PHPUnit/Integration/ReleaseCheckListTest.php @@ -216,14 +216,14 @@ class ReleaseCheckListTest extends \PHPUnit\Framework\TestCase $patternFailIfFound = 'jquery'; // known files that will for sure not contain a "buggy" $patternFailIfFound - $whiteListedFiles = array( + $allowedFiles = array( PIWIK_INCLUDE_PATH . '/plugins/TestRunner/templates/travis.yml.twig', PIWIK_INCLUDE_PATH . '/plugins/CoreUpdater/templates/layout.twig', PIWIK_INCLUDE_PATH . '/plugins/Installation/templates/layout.twig', PIWIK_INCLUDE_PATH . '/plugins/Login/templates/loginLayout.twig', PIWIK_INCLUDE_PATH . '/tests/UI/screenshot-diffs/singlediff.html', - // Note: entries below are paths and any file within these paths will be automatically whitelisted + // Note: entries below are paths and any file within these paths will be automatically allowed PIWIK_INCLUDE_PATH . '/tests/resources/overlay-test-site-real/', PIWIK_INCLUDE_PATH . '/tests/resources/overlay-test-site/', PIWIK_INCLUDE_PATH . '/vendor/lox/xhprof/xhprof_html/docs/', @@ -233,19 +233,19 @@ class ReleaseCheckListTest extends \PHPUnit\Framework\TestCase ); $files = Filesystem::globr(PIWIK_INCLUDE_PATH, '*.' . $extension); - $this->assertFilesDoNotContain($files, $patternFailIfFound, $whiteListedFiles); + $this->assertFilesDoNotContain($files, $patternFailIfFound, $allowedFiles); } /** * @param $files * @param $patternFailIfFound - * @param $whiteListedFiles + * @param $allowedFiles */ - private function assertFilesDoNotContain($files, $patternFailIfFound, $whiteListedFiles) + private function assertFilesDoNotContain($files, $patternFailIfFound, $allowedFiles) { $foundPatterns = array(); foreach ($files as $file) { - if($this->isFileOrPathWhitelisted($whiteListedFiles, $file)) { + if($this->isFileOrPathAllowed($allowedFiles, $file)) { continue; } $content = file_get_contents($file); @@ -265,14 +265,14 @@ class ReleaseCheckListTest extends \PHPUnit\Framework\TestCase } /** - * @param $whiteListedFiles + * @param $allowedFiles * @param $file * @return bool */ - private function isFileOrPathWhitelisted($whiteListedFiles, $file) + private function isFileOrPathAllowed($allowedFiles, $file) { - foreach ($whiteListedFiles as $whitelistFile) { - if (strpos($file, $whitelistFile) === 0) { + foreach ($allowedFiles as $allowedFile) { + if (strpos($file, $allowedFile) === 0) { return true; } } diff --git a/tests/PHPUnit/Integration/Settings/Measurable/MeasurablePropertyTest.php b/tests/PHPUnit/Integration/Settings/Measurable/MeasurablePropertyTest.php index 7c72668309..b057162632 100644 --- a/tests/PHPUnit/Integration/Settings/Measurable/MeasurablePropertyTest.php +++ b/tests/PHPUnit/Integration/Settings/Measurable/MeasurablePropertyTest.php @@ -49,7 +49,7 @@ class MeasurablePropertyTest extends IntegrationTestCase $this->assertNotDbConnectionCreated(); } - public function test_constructor_shouldThrowAnExceptionWhenNotWhitelistedNameIsUsed() + public function test_constructor_shouldThrowAnExceptionWhenNotAllowedNameIsUsed() { $this->expectException(\Exception::class); $this->expectExceptionMessage('Name "name" is not allowed to be used'); diff --git a/tests/UI/expected-screenshots/UIIntegrationTest_admin_diagnostics_configfile.png b/tests/UI/expected-screenshots/UIIntegrationTest_admin_diagnostics_configfile.png index ce1c85007a..fe89e281d0 100644 --- a/tests/UI/expected-screenshots/UIIntegrationTest_admin_diagnostics_configfile.png +++ b/tests/UI/expected-screenshots/UIIntegrationTest_admin_diagnostics_configfile.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5da65bc1d8b3188aef4387c78e857839a279d6ddddc3f0f1f3b2dfb3615ef83e -size 4448506 +oid sha256:f1107da0ab9dad0819d7190b7bd11045507bc9232e5be6d7506ce057058351e7 +size 4449780 |