diff --git a/composer.json b/composer.json index 0c92104..0494d8c 100644 --- a/composer.json +++ b/composer.json @@ -36,7 +36,8 @@ "phpunit/phpunit": "^7.0", "phpstan/phpstan": "^0.10.3", "squizlabs/php_codesniffer": "^3.3.2", - "zendframework/zend-diactoros": "^2.0" + "zendframework/zend-diactoros": "^2.0", + "php-http/psr7-integration-tests": "dev-master" }, "provide": { "php-http/message-factory": "^1.0" @@ -57,7 +58,7 @@ "@phpcs", "@phpstan" ], - "phpunit": "php vendor/bin/phpunit", + "phpunit": "php vendor/bin/phpunit --process-isolation", "phpcs": "php vendor/bin/phpcs", "phpstan": "php -d memory_limit=-1 vendor/bin/phpstan analyse src tests" } diff --git a/tests/Psr7Integration/Nyholm/ResponseTest.php b/tests/Psr7Integration/Nyholm/ResponseTest.php new file mode 100644 index 0000000..6dc9665 --- /dev/null +++ b/tests/Psr7Integration/Nyholm/ResponseTest.php @@ -0,0 +1,34 @@ +getResponseFactory(), + $provider->getStreamFactory() + ); + + return $decoratedResponseFactory->createResponse(); + } +} diff --git a/tests/Psr7Integration/Nyholm/ServerRequestTest.php b/tests/Psr7Integration/Nyholm/ServerRequestTest.php new file mode 100644 index 0000000..fbeb767 --- /dev/null +++ b/tests/Psr7Integration/Nyholm/ServerRequestTest.php @@ -0,0 +1,32 @@ +getServerRequestFactory()); + + return $decoratedServerRequestFactory->createServerRequest('GET', 'http://foo.com', $_SERVER); + } +} diff --git a/tests/Psr7Integration/Nyholm/UriTest.php b/tests/Psr7Integration/Nyholm/UriTest.php new file mode 100644 index 0000000..d98cffb --- /dev/null +++ b/tests/Psr7Integration/Nyholm/UriTest.php @@ -0,0 +1,32 @@ +getUriFactory()); + + return $decoratedUriFactory->createUri($uri); + } +} diff --git a/tests/Psr7Integration/Zend/ResponseTest.php b/tests/Psr7Integration/Zend/ResponseTest.php new file mode 100644 index 0000000..265446d --- /dev/null +++ b/tests/Psr7Integration/Zend/ResponseTest.php @@ -0,0 +1,34 @@ +getResponseFactory(), + $provider->getStreamFactory() + ); + + return $decoratedResponseFactory->createResponse(); + } +} diff --git a/tests/Psr7Integration/Zend/ServerRequestTest.php b/tests/Psr7Integration/Zend/ServerRequestTest.php new file mode 100644 index 0000000..0027529 --- /dev/null +++ b/tests/Psr7Integration/Zend/ServerRequestTest.php @@ -0,0 +1,31 @@ +getServerRequestFactory()); + + return $decoratedServerRequestFactory->createServerRequest('GET', 'http://foo.com', $_SERVER); + } +} diff --git a/tests/Psr7Integration/Zend/UriTest.php b/tests/Psr7Integration/Zend/UriTest.php new file mode 100644 index 0000000..f5fa18b --- /dev/null +++ b/tests/Psr7Integration/Zend/UriTest.php @@ -0,0 +1,31 @@ +getUriFactory()); + + return $decoratedUriFactory->createUri($uri); + } +}