PAN-6 Added the loadDb task to the build pipeline for Travis
This commit is contained in:
@@ -18,12 +18,15 @@ before_script:
|
|||||||
- mysql -u root pandamonium < pandamonium-theorem-prover/persistence/sql/local_development.sql
|
- mysql -u root pandamonium < pandamonium-theorem-prover/persistence/sql/local_development.sql
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
|
- name: load database
|
||||||
- name: build
|
- name: build
|
||||||
- name: unit Test
|
- name: unit Test
|
||||||
- name: integration Test
|
- name: integration Test
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
include:
|
include:
|
||||||
|
- stage: load database
|
||||||
|
script: ./pandamonium-theorem-prover/gradlew loaddb
|
||||||
- stage: build
|
- stage: build
|
||||||
script: ./pandamonium-theorem-prover/gradlew build
|
script: ./pandamonium-theorem-prover/gradlew build
|
||||||
- stage: unit Test
|
- stage: unit Test
|
||||||
|
|||||||
@@ -28,6 +28,6 @@ dependencies {
|
|||||||
}
|
}
|
||||||
|
|
||||||
task loadDb(type: Exec, group: 'Verification', description: 'Reloads the local database.') {
|
task loadDb(type: Exec, group: 'Verification', description: 'Reloads the local database.') {
|
||||||
workingDir "$rootDir/scripts/mysql"
|
workingDir "./scripts/mysql"
|
||||||
commandLine './loaddb.sh'
|
commandLine './loaddb.sh'
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
export MYSQL_PWD=secret
|
export MYSQL_PWD=secret
|
||||||
|
|
||||||
for sqlScript in $( find ../../ -name "*.sql" -print | sort);
|
for sqlScript in $( find . -name "*.sql" -print | sort);
|
||||||
do
|
do
|
||||||
echo "**** $sqlScript ****"
|
echo "**** $sqlScript ****"
|
||||||
mysql --batch --quick --raw --line-numbers --force --user=panda < $sqlScript
|
mysql --batch --quick --raw --line-numbers --force --user=panda < $sqlScript
|
||||||
|
|||||||
Reference in New Issue
Block a user