Skip to content

Commit

Permalink
Hopefully final bug fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
sjinks committed Jul 7, 2013
1 parent 1845cb6 commit 5461511
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 48 deletions.
7 changes: 5 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ before_install:
- ./unit-tests/ci/install_memcached.sh
- ./unit-tests/ci/install_apc.sh
- ./unit-tests/ci/install_mongo.sh
- sudo apt-get -qq install gdb

before_script:
- git submodule init
Expand Down Expand Up @@ -41,4 +40,8 @@ before_script:
- ulimit -c unlimited

script:
- ./unit-tests/ci/run_script.sh
- $(phpenv which php) ./unit-tests/ci/phpunit.php --debug -c unit-tests/phpunit.xml

after_failure:
- sudo apt-get -qq install gdb
- ./unit-tests/ci/after_failure.sh
16 changes: 16 additions & 0 deletions unit-tests/ci/after_failure.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash

shopt -s nullglob
export LC_ALL=C
for i in core core.*; do
if [ -f "$i" -a "$(file "$i" | grep -o 'core file')" ]; then
gdb -q $(file "$i" | grep -oE "'[^ ']+" | sed "s/^'//g") "$i" <<EOF
set pagination 0
backtrace full
info registers
x/16i \$pc
thread apply all backtrace
quit
EOF
fi
done
6 changes: 3 additions & 3 deletions unit-tests/ci/install_apc.sh
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
#! /bin/sh

if [ "$(php -r 'echo substr(PHP_VERSION, 0, 3);')" = "5.3" ]; then
wget http://pecl.php.net/get/apc-3.1.9.tgz
wget -q http://pecl.php.net/get/apc-3.1.9.tgz
tar -xzf apc-3.1.9.tgz
( cd APC-3.1.9 && phpize && ./configure --enable-apc && make && sudo make install )
echo "extension=apc.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
elif [ "$(php -r 'echo substr(PHP_VERSION, 0, 3);')" = "5.5" ]; then
wget http://pecl.php.net/get/apcu-4.0.1.tgz
wget -q http://pecl.php.net/get/apcu-4.0.1.tgz
tar xzf apcu-4.0.1.tgz
( cd apcu-4.0.1 && phpize && ./configure && make && sudo make install )
echo "extension=apcu.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
else
wget http://pecl.php.net/get/apc-3.1.13.tgz
wget -q http://pecl.php.net/get/apc-3.1.13.tgz
tar -xzf apc-3.1.13.tgz
( cd APC-3.1.13 && phpize && ./configure --enable-apc && make && sudo make install )
echo "extension=apc.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
Expand Down
10 changes: 5 additions & 5 deletions unit-tests/ci/install_memcached.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
#! /bin/sh

if [ "`php -r 'echo substr(PHP_VERSION, 0, 3);'`" = "5.3" ]; then
wget http://pecl.php.net/get/memcache-2.2.7.tgz
if [ "$(php -r 'echo substr(PHP_VERSION, 0, 3);')" = "5.3" ]; then
wget -q http://pecl.php.net/get/memcache-2.2.7.tgz
tar -xzf memcache-2.2.7.tgz
sh -c "cd memcache-2.2.7 && phpize && ./configure --enable-memcache && make && sudo make install"
( cd memcache-2.2.7 && phpize && ./configure --enable-memcache && make && sudo make install )
else
wget http://pecl.php.net/get/memcache-3.0.7.tgz
wget -q http://pecl.php.net/get/memcache-3.0.7.tgz
tar -xzf memcache-3.0.7.tgz
sh -c "cd memcache-3.0.7 && phpize && ./configure --enable-memcache && make && sudo make install"
( cd memcache-3.0.7 && phpize && ./configure --enable-memcache && make && sudo make install )
fi

echo "extension=memcache.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
4 changes: 2 additions & 2 deletions unit-tests/ci/install_mongo.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#! /bin/sh

wget http://pecl.php.net/get/mongo-1.3.4.tgz
wget -q http://pecl.php.net/get/mongo-1.3.4.tgz
tar -xzf mongo-1.3.4.tgz
sh -c "cd mongo-1.3.4 && phpize && ./configure --enable-memcache && make && sudo make install"
( cd mongo-1.3.4 && phpize && ./configure --enable-mongo && make && sudo make install )

echo "extension=mongo.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
36 changes: 0 additions & 36 deletions unit-tests/ci/run_script.sh

This file was deleted.

0 comments on commit 5461511

Please sign in to comment.