diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..0925d33 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,6 @@ +/.gitattributes export-ignore +/.gitignore export-ignore +/.travis.yml export-ignore +/examples/ export-ignore +/phpunit.xml.dist export-ignore +/tests/ export-ignore diff --git a/composer.json b/composer.json index c54b3ec..d47888c 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,7 @@ "react/stream": "^1.0 || ^0.7 || ^0.6" }, "require-dev": { - "phpunit/phpunit": "^5.0 || ^4.8", + "phpunit/phpunit": "^7.0 || ^6.0", "react/event-loop": "^1.0 || ^0.5 || ^0.4 || ^0.3" }, "suggest": { @@ -24,5 +24,8 @@ }, "autoload": { "psr-4": { "Clue\\React\\Zlib\\": "src/" } + }, + "autoload-dev": { + "psr-4": { "Clue\\Tests\\React\\Zlib\\": "tests/" } } } diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 4e6ec6c..a30c9fd 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,11 +1,6 @@ - + ./tests/ diff --git a/tests/CompressorTest.php b/tests/CompressorTest.php index 1d93db2..246eada 100644 --- a/tests/CompressorTest.php +++ b/tests/CompressorTest.php @@ -1,5 +1,7 @@ getMockBuilder('CallableStub')->getMock(); - } -} - -class CallableStub -{ - public function __invoke() - { + return $this->getMockBuilder('stdClass')->setMethods(array('__invoke'))->getMock(); } } diff --git a/tests/TransformStreamTest.php b/tests/TransformStreamTest.php index 87c25d2..1ad3fa0 100644 --- a/tests/TransformStreamTest.php +++ b/tests/TransformStreamTest.php @@ -1,5 +1,7 @@