More consistent loading of the test fixtures (#1506)

Remove db setup from the Haskell test suite and include it in the test bash scripts.
This commit is contained in:
Remo
2020-04-29 12:22:15 -05:00
committed by GitHub
parent d4cf8e7abb
commit 8b41b71db7
9 changed files with 18 additions and 27 deletions
+1 -8
View File
@@ -35,7 +35,6 @@ if [ "$#" -lt 1 ]; then
fi
rootdir="$(git rev-parse --show-toplevel)"
fixturesdir="$rootdir/test/fixtures"
# All data will be stored in a temporary directory.
tmpdir="$(mktemp -d)"
@@ -97,13 +96,7 @@ psql -v ON_ERROR_STOP=1 >> "$setuplog" << EOF
create extension pgcrypto;
alter database $PGDATABASE set request.jwt.claim.id = '-1';
alter role $PGUSER set default_text_search_config to english;
\i $fixturesdir/database.sql
\i $fixturesdir/roles.sql
\i $fixturesdir/schema.sql
\i $fixturesdir/jwt.sql
\i $fixturesdir/jsonschema.sql
\i $fixturesdir/privileges.sql
\i $rootdir/test/fixtures/load.sql
EOF
log "Done. Running command..."