This repository has been archived on 2024-09-05. You can view files and clone it, but cannot push or open issues or pull requests.
shimmie2/.travis.yml

50 lines
1.6 KiB
YAML
Raw Normal View History

2014-02-10 05:33:57 +00:00
language: php
2014-02-19 05:40:16 +00:00
2014-02-10 05:33:57 +00:00
php:
2014-02-19 05:40:16 +00:00
# Here is where we can list the versions of PHP you want to test against
2014-02-10 05:33:57 +00:00
# using major version aliases
- 5.3
# optionally specify a list of environments, for example to test different RDBMS
env:
- DB=mysql
# - DB=pgsql
before_install:
- sudo apt-get update > /dev/null
2014-02-18 03:56:32 +00:00
- sudo chmod u+x tests/setup_test_env.sh
2014-02-19 04:18:59 +00:00
install:
2014-02-19 05:40:16 +00:00
# Install nginx, php5-fpm and configure them
2014-02-18 03:56:32 +00:00
- sudo ./tests/setup_test_env.sh $TRAVIS_BUILD_DIR
2014-02-22 20:36:52 +00:00
2014-02-19 05:40:16 +00:00
# Create the database schema for shimmie.
2014-02-10 05:33:57 +00:00
- if [[ "$DB" == "pgsql" ]]; then psql -c "DROP DATABASE IF EXISTS shimmie;" -U postgres; fi
2014-02-19 05:40:16 +00:00
- if [[ "$DB" == "pgsql" ]]; then psql -c "CREATE DATABASE shimmie;" -U postgres; fi
- if [[ "$DB" == "mysql" ]]; then mysql -e "SET GLOBAL general_log = 'ON';" -uroot; fi
2014-02-19 05:40:16 +00:00
- if [[ "$DB" == "mysql" ]]; then mysql -e "CREATE DATABASE shimmie;" -uroot; fi
2014-02-19 04:02:10 +00:00
2014-02-19 04:18:59 +00:00
script:
- php tests/test_install.php -d $DB -h "http://127.0.0.1/"
2014-02-19 23:36:38 +00:00
- php tests/test_all.php -h "http://127.0.0.1/"
2014-02-10 05:33:57 +00:00
2014-02-18 08:42:59 +00:00
# If a failure occured then dump out a bunch of logs for debugging purposes.
2014-02-18 06:02:11 +00:00
after_failure:
2014-02-19 21:16:01 +00:00
- sudo ls -al
- sudo ls -al data/config/
2014-02-19 01:08:23 +00:00
- sudo cat data/config/shimmie.conf.php
- sudo cat data/config/extensions.conf.php
2014-02-22 01:04:12 +00:00
- sudo cat /etc/nginx/sites-enabled/default
- sudo cat /var/log/nginx/error.log
2014-02-19 21:24:47 +00:00
- sudo cat /var/log/php5-fpm.log
- sudo ls /var/run/mysql*
- sudo ls /var/log/*mysql*
2014-02-22 01:49:17 +00:00
- sudo cat /var/log/mysql.err
- sudo cat /var/log/mysql.log
- sudo cat /var/log/mysql/error.log
- sudo cat /var/log/mysql/slow.log
2014-02-18 06:02:11 +00:00
2014-02-10 05:33:57 +00:00
# configure notifications (email, IRC, campfire etc)
#notifications:
2014-02-19 21:16:01 +00:00
# irc: "irc.freenode.org#shimmie"
2014-02-10 05:33:57 +00:00
#