Skip to content

Commit d259285

Browse files
authored
Merge pull request #6 from php-http/Nyholm-patch-2
Add PHP requirements & travis fixes
2 parents 9bf1092 + b991153 commit d259285

File tree

3 files changed

+11
-6
lines changed

3 files changed

+11
-6
lines changed

.travis.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ cache:
99
php:
1010
- 7.0
1111
- 7.1
12-
- hhvm
1312

1413
env:
1514
global:
@@ -22,7 +21,7 @@ branches:
2221
matrix:
2322
fast_finish: true
2423
include:
25-
- php: 5.5
24+
- php: 7.0
2625
env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" COVERAGE=true TEST_COMMAND="composer test-ci"
2726

2827
before_install:
@@ -33,6 +32,9 @@ install:
3332
- if [[ "$COMPOSER_FLAGS" == *"--prefer-lowest"* ]]; then travis_retry composer update --prefer-dist --no-interaction --prefer-stable --quiet; fi
3433
- travis_retry composer update ${COMPOSER_FLAGS} --prefer-dist --no-interaction
3534

35+
before_script:
36+
- vendor/bin/http_test_server > /dev/null 2>&1 &
37+
3638
script:
3739
- $TEST_COMMAND
3840

composer.json

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,13 @@
1414
}
1515
},
1616
"require": {
17-
"amphp/artax": "^3",
17+
"php": "^7.0",
18+
"amphp/artax": "^3.0",
1819
"php-http/httplug": "^1.1",
1920
"php-http/discovery": "^1.2"
2021
},
2122
"require-dev": {
23+
"phpunit/phpunit": "^6.0",
2224
"amphp/phpunit-util": "^1",
2325
"php-http/client-integration-tests": "^0.6.0",
2426
"php-http/message": "^1.6"
@@ -27,6 +29,7 @@
2729
"php-http/client-implementation": "1.0"
2830
},
2931
"scripts": {
30-
"test": "vendor/bin/phpunit"
32+
"test": "vendor/bin/phpunit",
33+
"test-ci": "vendor/bin/phpunit --coverage-text --coverage-clover=build/coverage.xml"
3134
}
3235
}

phpunit.xml.dist

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<phpunit colors="true" bootstrap="vendor/autoload.php">
33
<testsuites>
44
<testsuite name="Artax Adapter Test Suite">
5-
<directory>test</directory>
5+
<directory>tests/</directory>
66
</testsuite>
77
</testsuites>
88
<php>
@@ -16,4 +16,4 @@
1616
<listeners>
1717
<listener class="Amp\PHPUnit\LoopReset" />
1818
</listeners>
19-
</phpunit>
19+
</phpunit>

0 commit comments

Comments
 (0)