Skip to content

Commit

Permalink
Raised testing support to PHP 7.3 and PHP 7.4
Browse files Browse the repository at this point in the history
  • Loading branch information
CristianLlanos committed Dec 7, 2020
1 parent e230be1 commit 1f10ed4
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 28 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.idea
/vendor
composer.lock
.phpunit.result.cache
3 changes: 1 addition & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
language: php

php:
- '5.6'
- '7.1'
- '7.3'
- '7.4'

sudo: false
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
},
"require-dev": {
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~5.0"
"mockery/mockery": ">=1.4",
"phpunit/phpunit": "^9"
},
"autoload": {
"psr-4": {
Expand Down
36 changes: 14 additions & 22 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -1,24 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="false"
backupStaticAttributes="false"
bootstrap="tests/bootstrap.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false">
<testsuites>
<testsuite name="Reliese Test Suite">
<directory suffix="Test.php">./tests</directory>
</testsuite>
</testsuites>
<filter>
<whitelist processUncoveredFilesFromWhitelist="true">
<directory suffix=".php">./src</directory>
</whitelist>
</filter>
<php>
<env name="APP_ENV" value="testing"/>
</php>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" backupGlobals="false" backupStaticAttributes="false" bootstrap="tests/bootstrap.php" colors="true" convertErrorsToExceptions="true" convertNoticesToExceptions="true" convertWarningsToExceptions="true" processIsolation="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd">
<coverage processUncoveredFiles="true">
<include>
<directory suffix=".php">./src</directory>
</include>
</coverage>
<testsuites>
<testsuite name="Reliese Test Suite">
<directory suffix="Test.php">./tests</directory>
</testsuite>
</testsuites>
<php>
<env name="APP_ENV" value="testing"/>
</php>
</phpunit>
4 changes: 2 additions & 2 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
* Created by Cristian.
* Date: 16/10/16 12:49 PM.
*/
class TestCase extends PHPUnit_Framework_TestCase
class TestCase extends \PHPUnit\Framework\TestCase
{
/**
* Clean up the testing environment before the next test.
*/
protected function tearDown()
protected function tearDown(): void
{
if (class_exists('Mockery')) {
Mockery::close();
Expand Down

0 comments on commit 1f10ed4

Please sign in to comment.