From 412aa2e820b6619f6159028b3925d6ac0b8384ad Mon Sep 17 00:00:00 2001 From: "Timothy J. Warren" Date: Tue, 12 Aug 2014 16:51:58 -0400 Subject: [PATCH] Another attempt to get travis ci working --- .travis.yml | 1 + application/config/testing-mysql/database.php | 62 +++++++++++++++++++ application/config/testing-pgsql/database.php | 62 +++++++++++++++++++ 3 files changed, 125 insertions(+) create mode 100644 application/config/testing-mysql/database.php create mode 100644 application/config/testing-pgsql/database.php diff --git a/.travis.yml b/.travis.yml index 1f13a58..94dbad9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,6 +16,7 @@ before_script: - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'DROP DATABASE IF EXISTS todo_test;' -U postgres; fi" - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'create database todo_test;' -U postgres; fi" - sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database IF NOT EXISTS todo_test;'; fi"; + - export ENVRIONMENT=testing-${DB} script: - vendor/bin/phinx migrate -e testing -c tests/phinx/$DB.yml diff --git a/application/config/testing-mysql/database.php b/application/config/testing-mysql/database.php new file mode 100644 index 0000000..b0555a9 --- /dev/null +++ b/application/config/testing-mysql/database.php @@ -0,0 +1,62 @@ + [ + 'hostname' => 'localhost', + 'username' => 'root', + 'password' => '', + 'database' => 'todo_test', + 'dbdriver' => 'mysqli', + 'dbprefix' => 'todo_', + 'pconnect' => FALSE, + 'db_debug' => TRUE, + 'cache_on' => FALSE, + 'cachedir' => '', + 'char_set' => 'utf8', + 'dbcollat' => 'utf8_general_ci', + 'swap_pre' => '', + 'autoinit' => FALSE, + 'stricton' => FALSE + ] +]; + + +/* End of file database.php */ +/* Location: ./system/application/config/database.php */ \ No newline at end of file diff --git a/application/config/testing-pgsql/database.php b/application/config/testing-pgsql/database.php new file mode 100644 index 0000000..9a62870 --- /dev/null +++ b/application/config/testing-pgsql/database.php @@ -0,0 +1,62 @@ + [ + 'hostname' => 'localhost', + 'username' => 'postgres', + 'password' => '', + 'database' => 'todo_test', + 'dbdriver' => 'postgre', + 'dbprefix' => 'todo_', + 'pconnect' => FALSE, + 'db_debug' => TRUE, + 'cache_on' => FALSE, + 'cachedir' => '', + 'char_set' => 'utf8', + 'dbcollat' => 'utf8_general_ci', + 'swap_pre' => '', + 'autoinit' => FALSE, + 'stricton' => FALSE + ] +]; + + +/* End of file database.php */ +/* Location: ./system/application/config/database.php */ \ No newline at end of file