From d73ae47431cb660e652bd2f4adbf8d2b3b4e9e68 Mon Sep 17 00:00:00 2001 From: Tim van Dijen Date: Sun, 26 Sep 2021 14:43:25 +0200 Subject: [PATCH] Remove some test-utils that were moved to the test-framework --- composer.json | 2 +- composer.lock | 138 +++++++++--------- tests/Utils/ArrayLogger.php | 31 ---- tests/Utils/ClearStateTestCase.php | 56 ------- tests/Utils/ReduceSpillOverTest.php | 45 ------ tests/Utils/StateClearer.php | 87 ----------- tests/bootstrap.php | 3 - tests/lib/SimpleSAML/Auth/SimpleTest.php | 2 +- tests/lib/SimpleSAML/Auth/SourceTest.php | 2 +- tests/lib/SimpleSAML/ConfigurationTest.php | 2 +- tests/lib/SimpleSAML/LoggerTest.php | 4 +- .../Metadata/MetaDataStorageHandlerTest.php | 2 +- .../lib/SimpleSAML/SessionHandlerPHPTest.php | 2 +- tests/lib/SimpleSAML/SessionTest.php | 2 +- tests/lib/SimpleSAML/Utils/EMailTest.php | 2 +- tests/lib/SimpleSAML/Utils/HTTPTest.php | 2 +- .../modules/core/lib/Controller/LoginTest.php | 2 +- .../lib/Auth/Source/MultiAuthTest.php | 2 +- tests/modules/saml/lib/Auth/Source/SPTest.php | 2 +- tests/modules/saml/lib/IdP/SAML2Test.php | 2 +- 20 files changed, 84 insertions(+), 306 deletions(-) delete mode 100644 tests/Utils/ArrayLogger.php delete mode 100644 tests/Utils/ClearStateTestCase.php delete mode 100644 tests/Utils/ReduceSpillOverTest.php delete mode 100644 tests/Utils/StateClearer.php diff --git a/composer.json b/composer.json index 593247318a..01ff8701f4 100644 --- a/composer.json +++ b/composer.json @@ -71,7 +71,7 @@ "ext-curl": "*", "mikey179/vfsstream": "~1.6", "simplesamlphp/simplesamlphp-module-adfs": "dev-master", - "simplesamlphp/simplesamlphp-test-framework": "^1.1.0", + "simplesamlphp/simplesamlphp-test-framework": "^1.1.3", "simplesamlphp/xml-security": "^0.2.7" }, "suggest": { diff --git a/composer.lock b/composer.lock index 9e0b6f35b0..0bab813cbc 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "b4be109aa063a98f4992cedcc5bbc5f9", + "content-hash": "a45a572469f4f9b24be5da3662672b97", "packages": [ { "name": "gettext/gettext", @@ -3129,25 +3129,25 @@ }, { "name": "twig/intl-extra", - "version": "v3.3.0", + "version": "v3.3.3", "source": { "type": "git", "url": "https://github.com/twigphp/intl-extra.git", - "reference": "919e8f945c30bd3efeb6a4d79722cda538116658" + "reference": "5a84d0f6bab386bc4224b4220da1daef8d015577" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/intl-extra/zipball/919e8f945c30bd3efeb6a4d79722cda538116658", - "reference": "919e8f945c30bd3efeb6a4d79722cda538116658", + "url": "https://api.github.com/repos/twigphp/intl-extra/zipball/5a84d0f6bab386bc4224b4220da1daef8d015577", + "reference": "5a84d0f6bab386bc4224b4220da1daef8d015577", "shasum": "" }, "require": { "php": ">=7.1.3", - "symfony/intl": "^4.3|^5.0", + "symfony/intl": "^4.3|^5.0|^6.0", "twig/twig": "^2.4|^3.0" }, "require-dev": { - "symfony/phpunit-bridge": "^4.4.9|^5.0.9" + "symfony/phpunit-bridge": "^4.4.9|^5.0.9|^6.0" }, "type": "library", "extra": { @@ -3182,7 +3182,7 @@ "twig" ], "support": { - "source": "https://github.com/twigphp/intl-extra/tree/v3.3.0" + "source": "https://github.com/twigphp/intl-extra/tree/v3.3.3" }, "funding": [ { @@ -3194,20 +3194,20 @@ "type": "tidelift" } ], - "time": "2021-01-01T14:58:18+00:00" + "time": "2021-05-20T14:28:34+00:00" }, { "name": "twig/twig", - "version": "v2.14.6", + "version": "v2.14.7", "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "27e5cf2b05e3744accf39d4c68a3235d9966d260" + "reference": "8e202327ee1ed863629de9b18a5ec70ac614d88f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/27e5cf2b05e3744accf39d4c68a3235d9966d260", - "reference": "27e5cf2b05e3744accf39d4c68a3235d9966d260", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/8e202327ee1ed863629de9b18a5ec70ac614d88f", + "reference": "8e202327ee1ed863629de9b18a5ec70ac614d88f", "shasum": "" }, "require": { @@ -3217,7 +3217,7 @@ }, "require-dev": { "psr/container": "^1.0", - "symfony/phpunit-bridge": "^4.4.9|^5.0.9" + "symfony/phpunit-bridge": "^4.4.9|^5.0.9|^6.0" }, "type": "library", "extra": { @@ -3261,7 +3261,7 @@ ], "support": { "issues": "https://github.com/twigphp/Twig/issues", - "source": "https://github.com/twigphp/Twig/tree/v2.14.6" + "source": "https://github.com/twigphp/Twig/tree/v2.14.7" }, "funding": [ { @@ -3273,7 +3273,7 @@ "type": "tidelift" } ], - "time": "2021-05-16T12:12:47+00:00" + "time": "2021-09-17T08:39:54+00:00" }, { "name": "webmozart/assert", @@ -3337,16 +3337,16 @@ "packages-dev": [ { "name": "amphp/amp", - "version": "v2.6.0", + "version": "v2.6.1", "source": { "type": "git", "url": "https://github.com/amphp/amp.git", - "reference": "caa95edeb1ca1bf7532e9118ede4a3c3126408cc" + "reference": "c5fc66a78ee38d7ac9195a37bacaf940eb3f65ae" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/amphp/amp/zipball/caa95edeb1ca1bf7532e9118ede4a3c3126408cc", - "reference": "caa95edeb1ca1bf7532e9118ede4a3c3126408cc", + "url": "https://api.github.com/repos/amphp/amp/zipball/c5fc66a78ee38d7ac9195a37bacaf940eb3f65ae", + "reference": "c5fc66a78ee38d7ac9195a37bacaf940eb3f65ae", "shasum": "" }, "require": { @@ -3414,7 +3414,7 @@ "support": { "irc": "irc://irc.freenode.org/amphp", "issues": "https://github.com/amphp/amp/issues", - "source": "https://github.com/amphp/amp/tree/v2.6.0" + "source": "https://github.com/amphp/amp/tree/v2.6.1" }, "funding": [ { @@ -3422,7 +3422,7 @@ "type": "github" } ], - "time": "2021-07-16T20:06:06+00:00" + "time": "2021-09-23T18:43:08+00:00" }, { "name": "amphp/byte-stream", @@ -3503,16 +3503,16 @@ }, { "name": "composer/package-versions-deprecated", - "version": "1.11.99.3", + "version": "1.11.99.4", "source": { "type": "git", "url": "https://github.com/composer/package-versions-deprecated.git", - "reference": "fff576ac850c045158a250e7e27666e146e78d18" + "reference": "b174585d1fe49ceed21928a945138948cb394600" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/fff576ac850c045158a250e7e27666e146e78d18", - "reference": "fff576ac850c045158a250e7e27666e146e78d18", + "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/b174585d1fe49ceed21928a945138948cb394600", + "reference": "b174585d1fe49ceed21928a945138948cb394600", "shasum": "" }, "require": { @@ -3556,7 +3556,7 @@ "description": "Composer plugin that provides efficient querying for installed package versions (no runtime IO)", "support": { "issues": "https://github.com/composer/package-versions-deprecated/issues", - "source": "https://github.com/composer/package-versions-deprecated/tree/1.11.99.3" + "source": "https://github.com/composer/package-versions-deprecated/tree/1.11.99.4" }, "funding": [ { @@ -3572,7 +3572,7 @@ "type": "tidelift" } ], - "time": "2021-08-17T13:49:14+00:00" + "time": "2021-09-13T08:41:34+00:00" }, { "name": "composer/semver", @@ -3928,16 +3928,16 @@ }, { "name": "mikey179/vfsstream", - "version": "v1.6.9", + "version": "v1.6.10", "source": { "type": "git", "url": "https://github.com/bovigo/vfsStream.git", - "reference": "2257e326dc3d0f50e55d0a90f71e37899f029718" + "reference": "250c0825537d501e327df879fb3d4cd751933b85" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/bovigo/vfsStream/zipball/2257e326dc3d0f50e55d0a90f71e37899f029718", - "reference": "2257e326dc3d0f50e55d0a90f71e37899f029718", + "url": "https://api.github.com/repos/bovigo/vfsStream/zipball/250c0825537d501e327df879fb3d4cd751933b85", + "reference": "250c0825537d501e327df879fb3d4cd751933b85", "shasum": "" }, "require": { @@ -3975,7 +3975,7 @@ "source": "https://github.com/bovigo/vfsStream/tree/master", "wiki": "https://github.com/bovigo/vfsStream/wiki" }, - "time": "2021-07-16T08:08:02+00:00" + "time": "2021-09-25T08:05:01+00:00" }, { "name": "myclabs/deep-copy", @@ -4088,16 +4088,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.12.0", + "version": "v4.13.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "6608f01670c3cc5079e18c1dab1104e002579143" + "reference": "50953a2691a922aa1769461637869a0a2faa3f53" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/6608f01670c3cc5079e18c1dab1104e002579143", - "reference": "6608f01670c3cc5079e18c1dab1104e002579143", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/50953a2691a922aa1769461637869a0a2faa3f53", + "reference": "50953a2691a922aa1769461637869a0a2faa3f53", "shasum": "" }, "require": { @@ -4138,9 +4138,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.12.0" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.13.0" }, - "time": "2021-07-21T10:44:31+00:00" + "time": "2021-09-20T12:20:58+00:00" }, { "name": "openlss/lib-array2xml", @@ -4417,16 +4417,16 @@ }, { "name": "phpdocumentor/type-resolver", - "version": "1.4.0", + "version": "1.5.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0" + "reference": "30f38bffc6f24293dadd1823936372dfa9e86e2f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0", - "reference": "6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/30f38bffc6f24293dadd1823936372dfa9e86e2f", + "reference": "30f38bffc6f24293dadd1823936372dfa9e86e2f", "shasum": "" }, "require": { @@ -4434,7 +4434,8 @@ "phpdocumentor/reflection-common": "^2.0" }, "require-dev": { - "ext-tokenizer": "*" + "ext-tokenizer": "*", + "psalm/phar": "^4.8" }, "type": "library", "extra": { @@ -4460,9 +4461,9 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.4.0" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.5.0" }, - "time": "2020-09-17T18:55:26+00:00" + "time": "2021-09-17T15:28:14+00:00" }, { "name": "phpspec/prophecy", @@ -4533,23 +4534,23 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.6", + "version": "9.2.7", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "f6293e1b30a2354e8428e004689671b83871edde" + "reference": "d4c798ed8d51506800b441f7a13ecb0f76f12218" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f6293e1b30a2354e8428e004689671b83871edde", - "reference": "f6293e1b30a2354e8428e004689671b83871edde", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/d4c798ed8d51506800b441f7a13ecb0f76f12218", + "reference": "d4c798ed8d51506800b441f7a13ecb0f76f12218", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.10.2", + "nikic/php-parser": "^4.12.0", "php": ">=7.3", "phpunit/php-file-iterator": "^3.0.3", "phpunit/php-text-template": "^2.0.2", @@ -4598,7 +4599,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.6" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.7" }, "funding": [ { @@ -4606,7 +4607,7 @@ "type": "github" } ], - "time": "2021-03-28T07:26:59+00:00" + "time": "2021-09-17T05:39:03+00:00" }, { "name": "phpunit/php-file-iterator", @@ -4851,16 +4852,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.9", + "version": "9.5.10", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "ea8c2dfb1065eb35a79b3681eee6e6fb0a6f273b" + "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/ea8c2dfb1065eb35a79b3681eee6e6fb0a6f273b", - "reference": "ea8c2dfb1065eb35a79b3681eee6e6fb0a6f273b", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c814a05837f2edb0d1471d6e3f4ab3501ca3899a", + "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a", "shasum": "" }, "require": { @@ -4876,7 +4877,7 @@ "phar-io/version": "^3.0.2", "php": ">=7.3", "phpspec/prophecy": "^1.12.1", - "phpunit/php-code-coverage": "^9.2.3", + "phpunit/php-code-coverage": "^9.2.7", "phpunit/php-file-iterator": "^3.0.5", "phpunit/php-invoker": "^3.1.1", "phpunit/php-text-template": "^2.0.3", @@ -4938,7 +4939,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.9" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.10" }, "funding": [ { @@ -4950,7 +4951,7 @@ "type": "github" } ], - "time": "2021-08-31T06:47:40+00:00" + "time": "2021-09-25T07:38:51+00:00" }, { "name": "sebastian/cli-parser", @@ -5805,7 +5806,6 @@ "type": "github" } ], - "abandoned": true, "time": "2020-09-28T06:45:17+00:00" }, { @@ -6008,23 +6008,23 @@ }, { "name": "simplesamlphp/simplesamlphp-test-framework", - "version": "v1.1.0", + "version": "v1.1.4", "source": { "type": "git", "url": "https://github.com/simplesamlphp/simplesamlphp-test-framework.git", - "reference": "2951b7b760a9f9b752debe5b8d7f191efd8cf1a7" + "reference": "a5f9d1f99aad4e3f843edd34796ecc59fba6a0c3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/simplesamlphp/simplesamlphp-test-framework/zipball/2951b7b760a9f9b752debe5b8d7f191efd8cf1a7", - "reference": "2951b7b760a9f9b752debe5b8d7f191efd8cf1a7", + "url": "https://api.github.com/repos/simplesamlphp/simplesamlphp-test-framework/zipball/a5f9d1f99aad4e3f843edd34796ecc59fba6a0c3", + "reference": "a5f9d1f99aad4e3f843edd34796ecc59fba6a0c3", "shasum": "" }, "require": { "php": ">=7.4", - "phpunit/phpunit": "^8.5|^9.0", - "squizlabs/php_codesniffer": "^3.5", - "vimeo/psalm": "^4.1" + "phpunit/phpunit": "^8.5|^9.5", + "squizlabs/php_codesniffer": "^3.6", + "vimeo/psalm": "^4.8" }, "require-dev": { "ext-curl": "*", @@ -6060,7 +6060,7 @@ "issues": "https://github.com/simplesamlphp/simplesamlphp-test-framework/issues", "source": "https://github.com/simplesamlphp/simplesamlphp-test-framework" }, - "time": "2021-03-14T00:30:00+00:00" + "time": "2021-09-26T13:02:27+00:00" }, { "name": "simplesamlphp/xml-common", diff --git a/tests/Utils/ArrayLogger.php b/tests/Utils/ArrayLogger.php deleted file mode 100644 index ac15538e79..0000000000 --- a/tests/Utils/ArrayLogger.php +++ /dev/null @@ -1,31 +0,0 @@ -logs[$level][] = $string; - } - - public function setLogFormat(string $format): void - { - // ignored - } -} diff --git a/tests/Utils/ClearStateTestCase.php b/tests/Utils/ClearStateTestCase.php deleted file mode 100644 index 644e4353f8..0000000000 --- a/tests/Utils/ClearStateTestCase.php +++ /dev/null @@ -1,56 +0,0 @@ -backupGlobals(); - } - } - - - /** - */ - protected function setUp(): void - { - self::clearState(); - } - - - /** - */ - public static function tearDownAfterClass(): void - { - self::clearState(); - } - - - /** - * Clear any SSP global state to reduce spill over between tests. - */ - public static function clearState(): void - { - self::$stateClearer->clearGlobals(); - self::$stateClearer->clearSSPState(); - } -} diff --git a/tests/Utils/ReduceSpillOverTest.php b/tests/Utils/ReduceSpillOverTest.php deleted file mode 100644 index ba57f9cbf4..0000000000 --- a/tests/Utils/ReduceSpillOverTest.php +++ /dev/null @@ -1,45 +0,0 @@ - 'b'], '[ARRAY]', 'simplesaml'); - $this->assertEquals('b', Configuration::getInstance()->getString('a')); - putenv('SIMPLESAMLPHP_CONFIG_DIR=' . __DIR__); - } - - - /** - * Confirm global state removed prior to next test - * @throws \SimpleSAML\Error\ConfigurationError - */ - public function testStateRemoved(): void - { - $this->assertArrayNotHasKey('QUERY_STRING', $_SERVER); - /** @var false $env */ - $env = getenv('SIMPLESAMLPHP_CONFIG_DIR'); - $this->assertFalse($env); - try { - Configuration::getInstance(); - $this->fail('Expected config configured in other tests to no longer be valid'); - } catch (Error\ConfigurationError $error) { - // Expected error - } - } -} diff --git a/tests/Utils/StateClearer.php b/tests/Utils/StateClearer.php deleted file mode 100644 index 569c8f90ee..0000000000 --- a/tests/Utils/StateClearer.php +++ /dev/null @@ -1,87 +0,0 @@ -backups['$_COOKIE'] = $_COOKIE; - $this->backups['$_ENV'] = $_ENV; - $this->backups['$_FILES'] = $_FILES; - $this->backups['$_GET'] = $_GET; - $this->backups['$_POST'] = $_POST; - $this->backups['$_SERVER'] = $_SERVER; - /** @psalm-var array|null $_SESSION */ - $this->backups['$_SESSION'] = isset($_SESSION) ? $_SESSION : []; - $this->backups['$_REQUEST'] = $_REQUEST; - } - - - /** - * Clear any global state. - */ - public function clearGlobals(): void - { - if (!empty($this->backups)) { - $_COOKIE = $this->backups['$_COOKIE']; - $_ENV = $this->backups['$_ENV']; - $_FILES = $this->backups['$_FILES']; - $_GET = $this->backups['$_GET']; - $_POST = $this->backups['$_POST']; - $_SERVER = $this->backups['$_SERVER']; - $_SESSION = $this->backups['$_SESSION']; - $_REQUEST = $this->backups['$_REQUEST']; - } else { - //TODO: what should this behavior be? - } - } - - - /** - * Clear any SSP specific state, such as SSP enviormental variables or cached internals. - */ - public function clearSSPState(): void - { - foreach ($this->clearableState as $var) { - $var::clearInternalState(); - } - - foreach ($this->vars_to_unset as $var) { - putenv($var); - } - } -} diff --git a/tests/bootstrap.php b/tests/bootstrap.php index 76e5b5f97e..796ba16b46 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -5,9 +5,6 @@ $projectRoot = dirname(__DIR__); require_once($projectRoot . '/vendor/autoload.php'); -// Current SSP autoloader can't resolve classes from the tests folder. -include($projectRoot . '/tests/Utils/ClearStateTestCase.php'); - // set the SAML2 container $container = new \SimpleSAML\Compat\SspContainer(); \SAML2\Compat\ContainerSingleton::setContainer($container); diff --git a/tests/lib/SimpleSAML/Auth/SimpleTest.php b/tests/lib/SimpleSAML/Auth/SimpleTest.php index 2c407cd491..ae8ce73292 100644 --- a/tests/lib/SimpleSAML/Auth/SimpleTest.php +++ b/tests/lib/SimpleSAML/Auth/SimpleTest.php @@ -7,7 +7,7 @@ use ReflectionClass; use SimpleSAML\Auth; use SimpleSAML\Configuration; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; /** * Tests for \SimpleSAML\Auth\Simple diff --git a/tests/lib/SimpleSAML/Auth/SourceTest.php b/tests/lib/SimpleSAML/Auth/SourceTest.php index 0d447cb6dd..443ad4a78a 100644 --- a/tests/lib/SimpleSAML/Auth/SourceTest.php +++ b/tests/lib/SimpleSAML/Auth/SourceTest.php @@ -6,7 +6,7 @@ use ReflectionClass; use SimpleSAML\Auth; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\Test\Utils\TestAuthSource; use SimpleSAML\Test\Utils\TestAuthSourceFactory; diff --git a/tests/lib/SimpleSAML/ConfigurationTest.php b/tests/lib/SimpleSAML/ConfigurationTest.php index 50455174d9..7950667680 100644 --- a/tests/lib/SimpleSAML/ConfigurationTest.php +++ b/tests/lib/SimpleSAML/ConfigurationTest.php @@ -8,7 +8,7 @@ use SAML2\Constants; use SimpleSAML\Configuration; use SimpleSAML\Error; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; /** * Tests for \SimpleSAML\Configuration diff --git a/tests/lib/SimpleSAML/LoggerTest.php b/tests/lib/SimpleSAML/LoggerTest.php index 6fdaf00394..a613cee8d0 100644 --- a/tests/lib/SimpleSAML/LoggerTest.php +++ b/tests/lib/SimpleSAML/LoggerTest.php @@ -8,12 +8,12 @@ use PHPUnit\Framework\TestCase; use SimpleSAML\Configuration; use SimpleSAML\Logger; -use SimpleSAML\Test\Utils\ArrayLogger; +use SimpleSAML\TestUtils\ArrayLogger; class LoggerTest extends TestCase { /** - * @var Logger\LoggingHandlerInterface|null + * @var \SimpleSAML\Logger\LoggingHandlerInterface|null */ protected $originalLogger; diff --git a/tests/lib/SimpleSAML/Metadata/MetaDataStorageHandlerTest.php b/tests/lib/SimpleSAML/Metadata/MetaDataStorageHandlerTest.php index 66739c3aad..dd881ab092 100644 --- a/tests/lib/SimpleSAML/Metadata/MetaDataStorageHandlerTest.php +++ b/tests/lib/SimpleSAML/Metadata/MetaDataStorageHandlerTest.php @@ -6,7 +6,7 @@ use SimpleSAML\Configuration; use SimpleSAML\Metadata\MetaDataStorageHandler; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; /** * @covers \SimpleSAML\Metadata\MetadataStorageHandler diff --git a/tests/lib/SimpleSAML/SessionHandlerPHPTest.php b/tests/lib/SimpleSAML/SessionHandlerPHPTest.php index 5e79591eac..e3c79e3ed3 100644 --- a/tests/lib/SimpleSAML/SessionHandlerPHPTest.php +++ b/tests/lib/SimpleSAML/SessionHandlerPHPTest.php @@ -5,7 +5,7 @@ namespace SimpleSAML\Test\Utils; use PHPUnit\Framework\TestCase; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\SessionHandlerPHP; use SimpleSAML\Configuration; diff --git a/tests/lib/SimpleSAML/SessionTest.php b/tests/lib/SimpleSAML/SessionTest.php index 1a75ba4388..b586532cf0 100644 --- a/tests/lib/SimpleSAML/SessionTest.php +++ b/tests/lib/SimpleSAML/SessionTest.php @@ -5,7 +5,7 @@ namespace SimpleSAML\Test\Utils; use PHPUnit\Framework\TestCase; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\Session; use SimpleSAML\Configuration; diff --git a/tests/lib/SimpleSAML/Utils/EMailTest.php b/tests/lib/SimpleSAML/Utils/EMailTest.php index f3b51427ab..a1dc4be039 100644 --- a/tests/lib/SimpleSAML/Utils/EMailTest.php +++ b/tests/lib/SimpleSAML/Utils/EMailTest.php @@ -7,7 +7,7 @@ use Exception; use InvalidArgumentException; use SimpleSAML\Configuration; -use SimpleSAML\Test\Utils\TestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\Utils\EMail; /** diff --git a/tests/lib/SimpleSAML/Utils/HTTPTest.php b/tests/lib/SimpleSAML/Utils/HTTPTest.php index 03a40a7b4d..907b0179c6 100644 --- a/tests/lib/SimpleSAML/Utils/HTTPTest.php +++ b/tests/lib/SimpleSAML/Utils/HTTPTest.php @@ -7,7 +7,7 @@ use PHPUnit\Framework\TestCase; use SimpleSAML\Configuration; use SimpleSAML\Error; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\Utils; /** diff --git a/tests/modules/core/lib/Controller/LoginTest.php b/tests/modules/core/lib/Controller/LoginTest.php index 3418852106..f204086633 100644 --- a/tests/modules/core/lib/Controller/LoginTest.php +++ b/tests/modules/core/lib/Controller/LoginTest.php @@ -13,7 +13,7 @@ use SimpleSAML\Locale\Localization; use SimpleSAML\Module\core\Controller; use SimpleSAML\Session; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\XHTML\Template; use Symfony\Component\HttpFoundation\RedirectResponse; use Symfony\Component\HttpFoundation\Request; diff --git a/tests/modules/multiauth/lib/Auth/Source/MultiAuthTest.php b/tests/modules/multiauth/lib/Auth/Source/MultiAuthTest.php index 5760e213d7..83be7f6e0d 100644 --- a/tests/modules/multiauth/lib/Auth/Source/MultiAuthTest.php +++ b/tests/modules/multiauth/lib/Auth/Source/MultiAuthTest.php @@ -6,7 +6,7 @@ use Error; use Exception; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\Configuration; use SimpleSAML\Module\multiauth\Auth\Source\MultiAuth; diff --git a/tests/modules/saml/lib/Auth/Source/SPTest.php b/tests/modules/saml/lib/Auth/Source/SPTest.php index bb5746072f..1bb6ab7009 100644 --- a/tests/modules/saml/lib/Auth/Source/SPTest.php +++ b/tests/modules/saml/lib/Auth/Source/SPTest.php @@ -16,7 +16,7 @@ use SimpleSAML\Module\saml\Error\NoAvailableIDP; use SimpleSAML\Module\saml\Error\NoSupportedIDP; use SimpleSAML\Test\Metadata\MetaDataStorageSourceTest; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; use SimpleSAML\Test\Utils\ExitTestException; use SimpleSAML\Test\Utils\SpTester; diff --git a/tests/modules/saml/lib/IdP/SAML2Test.php b/tests/modules/saml/lib/IdP/SAML2Test.php index 9f0b5906bc..1b017fe586 100644 --- a/tests/modules/saml/lib/IdP/SAML2Test.php +++ b/tests/modules/saml/lib/IdP/SAML2Test.php @@ -11,7 +11,7 @@ use SimpleSAML\Metadata\MetaDataStorageHandler; use SimpleSAML\Metadata\MetaDataStorageHandlerSerialize; use SimpleSAML\Module\saml\IdP\SAML2; -use SimpleSAML\Test\Utils\ClearStateTestCase; +use SimpleSAML\TestUtils\ClearStateTestCase; /** * @covers \SimpleSAML\Module\saml\IdP\SAML2