Skip to content
This repository was archived by the owner on Dec 14, 2023. It is now read-only.

Commit b043dc7

Browse files
authored
Upgrade PHPUnit to 6.x (#24)
* Upgrade PHPUnit to 6.x * Update CHANGELOG * Remove PHP 5.6 fom Travis config
1 parent 7e2f4a1 commit b043dc7

15 files changed

+39
-44
lines changed

.travis.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,12 @@ language: php
55
matrix:
66
fast_finish: true
77
include:
8-
- php: 5.6
98
- php: 7.0
109
env:
1110
- EXECUTE_COVERAGE=true
12-
- php: hhvm
11+
- php: 7.1
1312
allow_failures:
14-
- php: hhvm
13+
- php: 7.1
1514

1615
notifications:
1716
email: false

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,13 @@ All notable changes to this project will be documented in this file
33
using the [Keep a CHANGELOG](http://keepachangelog.com/) principles.
44
This project adheres to [Semantic Versioning](http://semver.org/).
55

6+
## [0.2.0] 2017-10-29
7+
8+
### Changed
9+
10+
- Upgrade minimum of PHP version up to 7.0
11+
- Upgrade minimum of PHPUnit version up to 6.0
12+
613
## [0.1.5] 2016-07-04
714

815
### Fixed

composer.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
],
1414
"minimum-stability": "stable",
1515
"require": {
16-
"justinrainbow/json-schema": "~2.0",
17-
"phpunit/phpunit": "~4.8|~5.0",
16+
"php": "~7.0",
1817
"psr/http-message": "~1.0",
19-
"php": "~5.6|~7.0"
18+
"phpunit/phpunit": "~6.0",
19+
"justinrainbow/json-schema": "~2.0"
2020
},
2121
"autoload": {
2222
"psr-4": {
@@ -26,7 +26,7 @@
2626
"require-dev": {
2727
"guzzlehttp/guzzle": "~6.2",
2828
"scrutinizer/ocular": "~1.1",
29-
"fabpot/php-cs-fixer": "~1.0"
29+
"friendsofphp/php-cs-fixer": "~2.0"
3030
},
3131
"autoload-dev": {
3232
"psr-4": {

phpunit.xml.dist

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<phpunit colors="true" convertNoticesToExceptions="true" convertWarningsToExceptions="true"
3-
stopOnError="false" stopOnFailure="false" stopOnIncomplete="false" stopOnSkipped="false"
4-
bootstrap="tests/Bootstrap.php">
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/6.3/phpunit.xsd"
4+
bootstrap="vendor/autoload.php"
5+
failOnRisky="true"
6+
failOnWarning="true"
7+
colors="true"
8+
verbose="true">
59
<testsuites>
610
<testsuite name="main">
7-
<directory suffix="Test.php">tests/</directory>
11+
<directory>tests/</directory>
812
</testsuite>
913
</testsuites>
1014
<filter>

src/PhpUnit/Asserts.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
namespace Rebilly\OpenAPI\PhpUnit;
1212

13-
use PHPUnit_Framework_Assert as Assert;
13+
use PHPUnit\Framework\Assert;
1414
use Psr\Http\Message\RequestInterface as Request;
1515
use Psr\Http\Message\ResponseInterface as Response;
1616
use Psr\Http\Message\StreamInterface as Stream;

src/PhpUnit/ContentTypeConstraint.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
namespace Rebilly\OpenAPI\PhpUnit;
1212

13-
use PHPUnit_Framework_Constraint as Constraint;
13+
use PHPUnit\Framework\Constraint\Constraint;
1414

1515
/**
1616
* Constraint that asserts that the content-type matches the expected types.

src/PhpUnit/HeadersConstraint.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
namespace Rebilly\OpenAPI\PhpUnit;
1212

13-
use PHPUnit_Framework_Constraint as Constraint;
13+
use PHPUnit\Framework\Constraint\Constraint;
1414
use Rebilly\OpenAPI\JsonSchema\Validator;
1515
use Rebilly\OpenAPI\UnexpectedValueException;
1616

src/PhpUnit/JsonSchemaConstraint.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@
1010

1111
namespace Rebilly\OpenAPI\PhpUnit;
1212

13-
use PHPUnit_Framework_Constraint as BaseConstraint;
13+
use PHPUnit\Framework\Constraint\Constraint;
1414
use Rebilly\OpenAPI\JsonSchema\Validator;
1515

1616
/**
1717
* Constraint that asserts that the object matches the expected JSON Schema.
1818
*/
19-
final class JsonSchemaConstraint extends BaseConstraint
19+
final class JsonSchemaConstraint extends Constraint
2020
{
2121
/**
2222
* @var object

src/PhpUnit/MethodsAllowedConstraint.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
namespace Rebilly\OpenAPI\PhpUnit;
1212

13-
use PHPUnit_Framework_Constraint as Constraint;
13+
use PHPUnit\Framework\Constraint\Constraint;
1414

1515
/**
1616
* Constraint that asserts that the HTTP method matches the expected allowed methods.

src/PhpUnit/UriConstraint.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
namespace Rebilly\OpenAPI\PhpUnit;
1212

13-
use PHPUnit_Framework_Constraint as Constraint;
13+
use PHPUnit\Framework\Constraint\Constraint;
1414
use Psr\Http\Message\UriInterface;
1515
use Rebilly\OpenAPI\JsonSchema\Validator;
1616
use Rebilly\OpenAPI\UnexpectedValueException;

0 commit comments

Comments
 (0)