Skip to content

Commit 76c3103

Browse files
committed
Merge pull request #1 from Nyholm/travis
Fix for APC on travis
2 parents e352705 + f6bc727 commit 76c3103

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

.travis.yml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
language: php
22
php:
3-
- 7.0
43
- 5.6
54
- 5.5
65
- hhvm
@@ -15,13 +14,12 @@ before_install:
1514
- pip install --user codecov
1615

1716
before_script:
18-
- mkdir -p ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d
19-
- echo "memory_limit=-1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
20-
- if [[ $TRAVIS_PHP_VERSION != 'hhvm' ]]; then pecl config-set preferred_state beta; printf "yes\n" | pecl install apcu; else echo "extension=apc.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi;
17+
# Install apc
18+
- if [ $TRAVIS_PHP_VERSION != 'hhvm' ]; then sh -c "yes '' | pecl install apcu-4.0.8"; fi
19+
- if [ $TRAVIS_PHP_VERSION != 'hhvm' ]; then phpenv config-add ./tests/travis/php.ini; fi
20+
2121
- travis_retry composer self-update
2222
- travis_retry composer install --prefer-source --no-interaction
23-
# must be set after composer to avoid issue with autoloading
24-
- echo "apc.enable_cli=On" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
2523

2624
script:
2725
- php -dzend_extension=xdebug.so vendor/bin/phpunit --coverage-clover=coverage.xml

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
],
2828
"require":
2929
{
30-
"php": "^5.5|^7.0",
30+
"php": "^5.5",
3131
"ext-apc": "*",
3232
"psr/cache": "1.0.0",
3333
"cache/adapter-common": "^0.1",

tests/travis/php.ini

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
apc.enabled=1
2+
apc.enable_cli=1

0 commit comments

Comments
 (0)