1
0
mirror of https://github.com/danog/file.git synced 2024-11-26 11:54:54 +01:00

Upgrade to PHPUnit 6

This commit is contained in:
Aaron Piotrowski 2017-05-17 22:58:39 -05:00
parent cadc86d85a
commit 32454e960b
5 changed files with 38 additions and 18 deletions

View File

@ -31,9 +31,10 @@
}, },
"minimum-stability": "dev", "minimum-stability": "dev",
"require-dev": { "require-dev": {
"amphp/phpunit-util": "dev-master",
"amphp/parallel": "dev-master as 0.1", "amphp/parallel": "dev-master as 0.1",
"phpunit/phpunit": "^5.0", "phpunit/phpunit": "^6.0",
"friendsofphp/php-cs-fixer": "~1.9" "friendsofphp/php-cs-fixer": "^2.3"
}, },
"suggest": { "suggest": {
"amphp/parallel": "Provides async file access without the eio or uv extension." "amphp/parallel": "Provides async file access without the eio or uv extension."

View File

@ -1,14 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit bootstrap="./vendor/autoload.php" colors="true">
<testsuites>
<testsuite name="Tests">
<directory>./test</directory>
</testsuite>
</testsuites>
<filter>
<whitelist addUncoveredFilesFromWhitelist="true">
<directory>./lib</directory>
</whitelist>
</filter>
</phpunit>

31
phpunit.xml.dist Normal file
View File

@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/4.1/phpunit.xsd"
backupGlobals="false"
backupStaticAttributes="false"
bootstrap="vendor/autoload.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false"
>
<testsuites>
<testsuite name="Amp Filesystem">
<directory>test</directory>
</testsuite>
</testsuites>
<filter>
<whitelist>
<directory suffix=".php">lib</directory>
</whitelist>
</filter>
<listeners>
<listener class="Amp\PHPUnit\LoopReset"/>
</listeners>
<logging>
<log type="coverage-html" target="build/coverage" title="Amp" highlight="true"/>
</logging>
</phpunit>

View File

@ -3,8 +3,9 @@
namespace Amp\File\Test; namespace Amp\File\Test;
use Amp\File as file; use Amp\File as file;
use Amp\PHPUnit\TestCase;
abstract class DriverTest extends \PHPUnit_Framework_TestCase { abstract class DriverTest extends TestCase {
private static $fixtureId; private static $fixtureId;
private static $umask; private static $umask;

View File

@ -3,8 +3,9 @@
namespace Amp\File\Test; namespace Amp\File\Test;
use Amp\File as file; use Amp\File as file;
use Amp\PHPUnit\TestCase;
abstract class HandleTest extends \PHPUnit_Framework_TestCase { abstract class HandleTest extends TestCase {
public static function setUpBeforeClass() { public static function setUpBeforeClass() {
Fixture::init(); Fixture::init();
} }