Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix schema migration test #7483

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion susemanager-utils/testing/automation/VERSION.SUSE-Manager
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ REPORTDB_DOC_CONTAINER=devel/galaxy/manager/head/docker/containers/suma-$VER-rep
# This value is is used if the file for the PR is not found (we assume we are on a branch)
IDEMPOTENCY_SCHEMA_BASE_VERSION='4.3.8'
IDEMPOTENCY_REPORTDB_SCHEMA_BASE_VERSION='4.3.1'
SCHEMA_PACKAGES='susemanager-schema-4.3.8-150400.1.5.noarch.rpm'
SCHEMA_PACKAGES='susemanager-schema-4.3.8-150400.1.5.noarch.rpm susemanager-schema-utility-4.3.8-150400.1.5.noarch.rpm'
REPORTDB_SCHEMA_PACKAGES='susemanager-schema-4.3.8-150400.1.5.noarch.rpm susemanager-schema-utility-4.3.8-150400.1.5.noarch.rpm uyuni-reportdb-schema-4.3.1-150400.1.5.noarch.rpm'
BRAND_NAME='SUSE Manager'
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ else
fi

INITIAL_CMD="/manager/susemanager-utils/testing/automation/initial-objects.sh"
MIGRATION_TEST="/manager/susemanager-utils/testing/docker/scripts/schema_migration_test_pgsql.sh ${SCHEMA_PACKAGES}"
MIGRATION_TEST="/manager/susemanager-utils/testing/docker/scripts/schema_migration_test_pgsql.sh \"${SCHEMA_PACKAGES}\""
IDEMPOTENCY_TEST="/manager/susemanager-utils/testing/docker/scripts/schema_idempotency_test_pgsql.py ${IDEMPOTENCY_PARAMS}"
CHOWN_CMD="/manager/susemanager-utils/testing/automation/chown-objects.sh $(id -u) $(id -g)"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,14 @@ if [ ${#} -ne 1 ];then
usage_and_exit ${SCRIPT}
fi

schema_rpm=${1}
schema_rpms=${1}

if [ ! -f /root/${schema_rpm} ];then
echo "RPM /root/${schema_rpm} does not exists"
usage_and_exit ${SCRIPT}
fi
for i in ${schema_rpms};do
if [ ! -f /root/${i} ];then
echo "RPM /root/${i} does not exists"
usage_and_exit ${SCRIPT}
fi
done

cd /manager/susemanager-utils/testing/docker/scripts/

Expand All @@ -35,7 +37,7 @@ fi
# Database schema creation

pushd /root/
rpm -ivh ${schema_rpm}
rpm -ivh ${schema_rpms}
popd

export PERLLIB=/manager/spacewalk/setup/lib/:/manager/web/modules/rhn/:/manager/web/modules/pxt/:/manager/schema/spacewalk/lib
Expand Down