Skip to content

Commit be79e50

Browse files
committed
Merge pull request #53 from php-http/hhvm
Make sure travis can run on HHVM
2 parents f5c7b0d + 0bf9840 commit be79e50

File tree

4 files changed

+17
-3
lines changed

4 files changed

+17
-3
lines changed

.travis.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ branches:
2626

2727
matrix:
2828
fast_finish: true
29-
allow_failures:
30-
- php: hhvm
3129
include:
3230
- php: 5.5
3331
env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" COVERAGE=true TEST_COMMAND="composer test-ci" SYMFONY_VERSION=2.7.*

Tests/Resources/app/AppKernel.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,11 @@ public function registerBundles()
2121
*/
2222
public function registerContainerConfiguration(LoaderInterface $loader)
2323
{
24-
$loader->load(__DIR__.'/config/config.yml');
24+
$runtime = 'php';
25+
if (defined('HHVM_VERSION')) {
26+
$runtime = 'hhvm';
27+
}
28+
$loader->load(__DIR__.'/config/config_'.$runtime.'.yml');
2529
}
2630

2731
/**
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
framework:
2+
secret: php-http
3+
test: ~
4+
5+
# Do not use auto discovery
6+
httplug:
7+
classes:
8+
client: Http\Adapter\Guzzle6\Client
9+
message_factory: Http\Message\MessageFactory\GuzzleMessageFactory
10+
uri_factory: Http\Message\UriFactory\GuzzleUriFactory
11+
stream_factory: Http\Message\StreamFactory\GuzzleStreamFactory

Tests/Resources/app/config/config.yml renamed to Tests/Resources/app/config/config_php.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@ framework:
22
secret: php-http
33
test: ~
44

5+
# Use auto discovery
56
httplug: ~

0 commit comments

Comments
 (0)