Skip to content

Commit

Permalink
Use officially released image for testing
Browse files Browse the repository at this point in the history
Test both templates in postgresql_imagestream test

Signed-off-by: Petr "Stone" Hracek <[email protected]>
  • Loading branch information
phracek committed Nov 30, 2023
1 parent 6a37e25 commit 77ac497
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions test/test-lib-postgresql.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function test_postgresql_integration() {
ct_os_test_template_app_func "${IMAGE_NAME}" \
"${THISDIR}/examples/${template}" \
"${service_name}" \
"ct_os_check_cmd_internal '<SAME_IMAGE>' '${service_name}-testing' 'PGPASSWORD=testp pg_isready -t 15 -h <IP> -U testu -d testdb' 'accepting connections' 120" \
"ct_os_check_cmd_internal 'registry.redhat.io/${OS}/postgresql-${VERSION}' '${service_name}-testing' 'PGPASSWORD=testp pg_isready -t 15 -h <IP> -U testu -d testdb' 'accepting connections' 120" \
"-p POSTGRESQL_VERSION=${VERSION} \
-p DATABASE_SERVICE_NAME="${service_name}-testing" \
-p POSTGRESQL_USER=testu \
Expand All @@ -37,8 +37,11 @@ function test_postgresql_imagestream() {
elif [ "${OS}" == "rhel9" ]; then
tag="-el9"
fi

ct_os_test_image_stream_template "${THISDIR}/imagestreams/postgresql-${OS%[0-9]*}.json" "${THISDIR}/examples/postgresql-ephemeral-template.json" postgresql "-p POSTGRESQL_VERSION=${VERSION}${tag}"
TEMPLATES="postgresql-ephemeral-template.json
postgresql-persistent-template.json"
for template in $TEMPLATES; do
ct_os_test_image_stream_template "${THISDIR}/imagestreams/postgresql-${OS%[0-9]*}.json" "${THISDIR}/examples/${template}" postgresql "-p POSTGRESQL_VERSION=${VERSION}${tag}"
done
}


Expand Down

0 comments on commit 77ac497

Please sign in to comment.