Skip to content

Commit

Permalink
Initialize support for php 8
Browse files Browse the repository at this point in the history
  • Loading branch information
adriansuter committed Jul 1, 2020
1 parent 9a0359f commit 50ae7b6
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
@@ -1,5 +1,6 @@
.DS_Store
.idea
.phpunit.result.cache
composer.lock
coverage
docs/_site
Expand Down
4 changes: 4 additions & 0 deletions .travis.yml
Expand Up @@ -9,6 +9,10 @@ matrix:
- php: 7.3
- php: 7.4
env: ANALYSIS='true'
- php: nightly

allow_failures:
- php: nightly

before_script:
- if [[ "$ANALYSIS" == 'true' ]]; then composer require php-coveralls/php-coveralls:^2.2.0 ; fi
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Expand Up @@ -34,12 +34,12 @@
]
},
"require": {
"php": "^7.1",
"php": "^7.2 || ^8.0",
"nikic/php-parser": "^4.4"
},
"require-dev": {
"phpstan/phpstan": "^0.12.25",
"phpunit/phpunit": "^7.5",
"phpunit/phpunit": "^8.5",
"squizlabs/php_codesniffer": "^3.5"
},
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion phpunit.xml.dist
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/7.1/phpunit.xsd"
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/8.5/phpunit.xsd"
backupGlobals="true"
beStrictAboutOutputDuringTests="true"
colors="true"
Expand Down
4 changes: 2 additions & 2 deletions tests/AbstractIntegrationTest.php
Expand Up @@ -19,12 +19,12 @@ abstract class AbstractIntegrationTest extends TestCase

private static $classLoader;

public static function setUpBeforeClass()
public static function setUpBeforeClass(): void
{
self::$classLoader = require(__DIR__ . '/../vendor/autoload.php');
}

protected function setUp()
protected function setUp(): void
{
parent::setUp();
if (!$this->overrideApplied) {
Expand Down
2 changes: 1 addition & 1 deletion tests/FileStreamWrapperTest.php
Expand Up @@ -22,7 +22,7 @@ final class FileStreamWrapperTest extends TestCase
*/
private $tempFilePath;

protected function tearDown()
protected function tearDown(): void
{
// Make sure that we restore the default file stream wrapper.
\stream_wrapper_restore('file');
Expand Down
2 changes: 1 addition & 1 deletion tests/IntegrationCustomNamespaceTest.php
Expand Up @@ -12,7 +12,7 @@

class IntegrationCustomNamespaceTest extends AbstractIntegrationTest
{
public static function setUpBeforeClass()
public static function setUpBeforeClass(): void
{
require_once(__DIR__ . '/assets/PHPCustomAutoloadOverride.php');
}
Expand Down
2 changes: 1 addition & 1 deletion tests/IntegrationNamespaceTest.php
Expand Up @@ -12,7 +12,7 @@

class IntegrationNamespaceTest extends AbstractIntegrationTest
{
public static function setUpBeforeClass()
public static function setUpBeforeClass(): void
{
require_once(__DIR__ . '/assets/PHPAutoloadOverride.php');
}
Expand Down

0 comments on commit 50ae7b6

Please sign in to comment.