Skip to content

Commit

Permalink
Merge pull request #47 from creative-commoners/pulls/1/sapphire-test-…
Browse files Browse the repository at this point in the history
…nine

API phpunit 9 support
  • Loading branch information
Maxime Rainville authored Nov 2, 2021
2 parents 205d8d6 + 7d660c1 commit a0f963b
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 18 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ env:
jobs:
fast_finish: true
include:
- php: 7.1
- php: 7.3
env:
- COMPOSER_INSTALL_ARG=--prefer-lowest
- php: 7.3
- php: 7.4
env:
- PHPCS_TEST=1
- php: 7.4
env:
- php: nightly
- php: 8.0
env:
- COMPOSER_INSTALL_ARG=--ignore-platform-reqs
9 changes: 3 additions & 6 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,7 @@
}
},
"extra": {
"class": "SilverStripe\\VendorPlugin\\VendorPlugin",
"branch-alias": {
"1.x-dev": "1.4.x-dev"
}
"class": "SilverStripe\\VendorPlugin\\VendorPlugin"
},
"scripts": {
"lint": "phpcs src/ tests/",
Expand All @@ -28,11 +25,11 @@
"require": {
"composer/installers": "^1.4",
"composer-plugin-api": "^1.1 || ^2",
"php": "^7.1 || ^8"
"php": "^7.3 || ^8"
},
"require-dev": {
"composer/composer": "^1.5 || ^2@rc",
"sminnee/phpunit": "^5.7",
"phpunit/phpunit": "^9.5",
"squizlabs/php_codesniffer": "^3"
}
}
8 changes: 5 additions & 3 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit colors="true">
<testsuite name="Default">
<directory>tests/</directory>
</testsuite>
<testsuites>
<testsuite name="Default">
<directory>tests/</directory>
</testsuite>
</testsuites>
</phpunit>
4 changes: 2 additions & 2 deletions tests/Methods/ChainedMethodTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class ChainedMethodTest extends TestCase
*/
protected $root = null;

protected function setUp()
protected function setUp(): void
{
parent::setUp();

Expand All @@ -37,7 +37,7 @@ protected function setUp()
$this->filesystem->ensureDirectoryExists($this->root);
}

protected function tearDown()
protected function tearDown(): void
{
$this->filesystem->remove($this->root);
parent::tearDown();
Expand Down
4 changes: 2 additions & 2 deletions tests/Methods/CopyMethodTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class CopyMethodTest extends TestCase
*/
protected $root = null;

protected function setUp()
protected function setUp(): void
{
parent::setUp();

Expand All @@ -36,7 +36,7 @@ protected function setUp()
$this->filesystem->ensureDirectoryExists($this->root);
}

protected function tearDown()
protected function tearDown(): void
{
$this->filesystem->remove($this->root);
parent::tearDown();
Expand Down
4 changes: 2 additions & 2 deletions tests/Methods/SymlinkMethodTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class SymlinkMethodTest extends TestCase
*/
protected $root = null;

protected function setUp()
protected function setUp(): void
{
parent::setUp();

Expand All @@ -37,7 +37,7 @@ protected function setUp()
$this->filesystem->ensureDirectoryExists($this->root);
}

protected function tearDown()
protected function tearDown(): void
{
$this->filesystem->remove($this->root);
parent::tearDown();
Expand Down

0 comments on commit a0f963b

Please sign in to comment.