Merge "Load several fixtures when tesing"

This commit is contained in:
Jenkins 2016-02-02 08:46:28 +00:00 committed by Gerrit Code Review
commit b46960133e
2 changed files with 5 additions and 4 deletions

View File

@ -67,8 +67,10 @@ EOL
prepare_server() {
python ${NAILGUN_ROOT}/manage.py syncdb > /dev/null
python ${NAILGUN_ROOT}/manage.py loaddefault > /dev/null
if test "$NAILGUN_SAMPLE_LOAD" = "yes"; then
python ${NAILGUN_ROOT}/manage.py loaddata $NAILGUN_SAMPLE_FILE > /dev/null
if test -n "$NAILGUN_FIXTURE_FILES"; then
for nailgun_fixture_file in $NAILGUN_FIXTURE_FILES; do
python ${NAILGUN_ROOT}/manage.py loaddata $nailgun_fixture_file > /dev/null
done
fi
python ${NAILGUN_ROOT}/manage.py run \

View File

@ -23,8 +23,7 @@ setenv =
NAILGUN_ROOT={toxinidir}/nailgun
NAILGUN_STATIC={toxinidir}/nailgun/static
NAILGUN_TEMPLATES={toxinidir}/nailgun/static
NAILGUN_SAMPLE_FILE={toxinidir}/nailgun/nailgun/fixtures/sample_environment.json
NAILGUN_SAMPLE_LOAD=no
NAILGUN_FIXTURE_FILES={env:NAILGUN_FIXTURE_FILES:}
NAILGUN_CONFIG={[base]ARTS}/test.yaml
NAILGUN_LOGS={[base]ARTS}