2014-05-05 22:42:15 +02:00
|
|
|
language: erlang
|
|
|
|
|
|
|
|
otp_release:
|
2019-10-25 13:56:19 +02:00
|
|
|
- 19.3
|
2021-02-01 13:50:04 +01:00
|
|
|
- 23.1.2
|
2014-05-05 22:42:15 +02:00
|
|
|
|
2020-06-08 10:38:45 +02:00
|
|
|
os: linux
|
|
|
|
|
|
|
|
dist: xenial
|
|
|
|
|
2014-07-15 20:42:12 +02:00
|
|
|
services:
|
2020-06-08 02:28:32 +02:00
|
|
|
- redis
|
2021-02-02 14:59:42 +01:00
|
|
|
- mysql
|
2019-06-15 12:41:13 +02:00
|
|
|
- postgresql
|
2014-07-15 20:42:12 +02:00
|
|
|
|
2014-05-05 22:42:15 +02:00
|
|
|
before_install:
|
|
|
|
- sudo apt-get -qq update
|
2016-03-21 12:15:07 +01:00
|
|
|
- pip install --user coveralls-merge
|
2014-05-05 22:42:15 +02:00
|
|
|
|
|
|
|
install:
|
2017-09-25 10:19:49 +02:00
|
|
|
- sudo apt-get -qq install libexpat1-dev libyaml-dev libpam0g-dev libsqlite3-dev libgd-dev libwebp-dev
|
2014-05-05 22:42:15 +02:00
|
|
|
|
|
|
|
before_script:
|
2016-03-23 16:16:50 +01:00
|
|
|
# Ulimit: See Travis-CI issue report: https://github.com/travis-ci/travis-ci/issues/3328
|
2014-05-05 22:42:15 +02:00
|
|
|
- mysql -u root -e "CREATE USER 'ejabberd_test'@'localhost' IDENTIFIED BY 'ejabberd_test';"
|
|
|
|
- mysql -u root -e "CREATE DATABASE ejabberd_test;"
|
|
|
|
- mysql -u root -e "GRANT ALL ON ejabberd_test.* TO 'ejabberd_test'@'localhost';"
|
2018-11-19 12:49:29 +01:00
|
|
|
- mysql -u root ejabberd_test < sql/mysql.sql
|
2014-05-05 22:42:15 +02:00
|
|
|
- psql -U postgres -c "CREATE USER ejabberd_test WITH PASSWORD 'ejabberd_test';"
|
|
|
|
- psql -U postgres -c "CREATE DATABASE ejabberd_test;"
|
2018-11-19 12:58:45 +01:00
|
|
|
- psql -U postgres ejabberd_test -f sql/pg.sql
|
2018-11-19 13:16:51 +01:00
|
|
|
- psql -U postgres -c "GRANT ALL PRIVILEGES ON DATABASE ejabberd_test TO ejabberd_test;"
|
2018-11-19 13:53:06 +01:00
|
|
|
- psql -U postgres ejabberd_test -c "GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO ejabberd_test;"
|
2019-10-31 09:00:02 +01:00
|
|
|
- psql -U postgres ejabberd_test -c "GRANT ALL PRIVILEGES ON ALL SEQUENCES IN SCHEMA public TO ejabberd_test;"
|
2014-05-05 22:42:15 +02:00
|
|
|
|
|
|
|
script:
|
|
|
|
- ./autogen.sh
|
2019-07-18 18:31:12 +02:00
|
|
|
- ./configure --prefix=/tmp/ejabberd --enable-all --disable-odbc --disable-elixir
|
2015-10-19 14:23:37 +02:00
|
|
|
- make
|
2018-01-31 17:54:32 +01:00
|
|
|
- make install -s
|
2014-10-30 18:26:42 +01:00
|
|
|
- make xref
|
2019-05-15 20:47:39 +02:00
|
|
|
- ./tools/hook_deps.sh ebin
|
2016-03-15 18:14:27 +01:00
|
|
|
- sed -i -e 's/ct:pal/ct:log/' test/suite.erl
|
|
|
|
- ln -sf ../sql priv/
|
2018-01-31 17:03:18 +01:00
|
|
|
- echo "" >> rebar.config
|
2018-01-31 17:10:05 +01:00
|
|
|
- echo '{ct_extra_params, "-verbosity 20"}.' >> rebar.config
|
2018-01-31 17:03:18 +01:00
|
|
|
- escript ./rebar skip_deps=true ct -v
|
2018-01-31 17:54:32 +01:00
|
|
|
- grep -q 'TEST COMPLETE,.* 0 failed' logs/raw.log
|
2019-11-08 07:35:12 +01:00
|
|
|
- test $(find logs -empty -name error.log)
|
2014-05-05 22:42:15 +02:00
|
|
|
|
|
|
|
after_script:
|
|
|
|
- find logs -name suite.log -exec cat '{}' ';'
|
|
|
|
|
|
|
|
after_failure:
|
2016-04-06 17:55:56 +02:00
|
|
|
- find logs -name exunit.log -exec cat '{}' ';'
|
2014-05-05 22:42:15 +02:00
|
|
|
- find logs -name ejabberd.log -exec cat '{}' ';'
|
2019-10-31 09:18:59 +01:00
|
|
|
- find logs -name suite.log -exec cat '{}' ';' | awk 'BEGIN{RS="\n=case";FS="\n"} /=result\s*failed/ {print "=case" $0}'
|
2014-05-05 22:42:15 +02:00
|
|
|
|
2016-03-21 12:01:20 +01:00
|
|
|
after_success:
|
2016-03-21 12:15:07 +01:00
|
|
|
- coveralls-merge erlang.json
|
2016-03-21 12:01:20 +01:00
|
|
|
|
2014-05-05 22:42:15 +02:00
|
|
|
notifications:
|
|
|
|
email: false
|