From 1b141267f6c34023767df11c29c1bc62d13ba08a Mon Sep 17 00:00:00 2001 From: Martijn Vermaat <martijn@vermaat.name> Date: Mon, 10 Aug 2015 16:31:50 +0200 Subject: [PATCH] On Travis CI also run tests with PostgreSQL and MySQL --- .travis.yml | 9 ++++++++- doc/testing.rst | 4 ++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index bfd46701..b78e6379 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,9 +6,16 @@ before_install: - sudo apt-get update -qq - sudo apt-get install -y swig - pip install -r requirements.txt + - pip install psycopg2 install: - pip install . -script: py.test +before_script: + - psql -c 'create database mutalyzer_test;' -U postgres + - mysql -e 'create database mutalyzer_test;' +script: + - py.test + - MUTALYZER_TEST_DATABASE_URI=postgres://postgres@127.0.0.1/mutalyzer_test py.test + - MUTALYZER_TEST_DATABASE_URI=mysql://travis@127.0.0.1/mutalyzer_test?charset=utf8 py.test notifications: slack: secure: "VsB4CPZCfUPpnt7sL94mYrws2B9VthQhY1+u7NBm6QkAopel0m1rx1vWx3gQCTR0t9vWiP+pSybtQ81PQFNrOSWDsb1QlyEK1JF1QUw5Zui+5wS8fwFM/sgwGIECuo6Oj0zCwC9KMM4olYEMC2c7TNHv4HgwWiMqEK9ItEYSLQY=" diff --git a/doc/testing.rst b/doc/testing.rst index db9f7802..9a3ae4b9 100644 --- a/doc/testing.rst +++ b/doc/testing.rst @@ -32,8 +32,8 @@ PostgreSQL:: $ pg_virtualenv bash -c 'MUTALYZER_TEST_DATABASE_URI=postgres://${PGUSER}:${PGPASSWORD}@${PGHOST}:${PGPORT}/${PGDATABASE} py.test' Tests are `run automatically on Travis CI -<https://travis-ci.org/LUMC/mutalyzer>`_ for each pull request and push on -GitHub. +<https://travis-ci.org/LUMC/mutalyzer>`_ with SQLite, PostgreSQL, and MySQL, +for each pull request and push on GitHub. Testing the web services -- GitLab