Skip to content

Commit 77ac497

Browse files
committed
Use officially released image for testing
Test both templates in postgresql_imagestream test Signed-off-by: Petr "Stone" Hracek <[email protected]>
1 parent 6a37e25 commit 77ac497

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

test/test-lib-postgresql.sh

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ function test_postgresql_integration() {
2020
ct_os_test_template_app_func "${IMAGE_NAME}" \
2121
"${THISDIR}/examples/${template}" \
2222
"${service_name}" \
23-
"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" \
23+
"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" \
2424
"-p POSTGRESQL_VERSION=${VERSION} \
2525
-p DATABASE_SERVICE_NAME="${service_name}-testing" \
2626
-p POSTGRESQL_USER=testu \
@@ -37,8 +37,11 @@ function test_postgresql_imagestream() {
3737
elif [ "${OS}" == "rhel9" ]; then
3838
tag="-el9"
3939
fi
40-
41-
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}"
40+
TEMPLATES="postgresql-ephemeral-template.json
41+
postgresql-persistent-template.json"
42+
for template in $TEMPLATES; do
43+
ct_os_test_image_stream_template "${THISDIR}/imagestreams/postgresql-${OS%[0-9]*}.json" "${THISDIR}/examples/${template}" postgresql "-p POSTGRESQL_VERSION=${VERSION}${tag}"
44+
done
4245
}
4346

4447

0 commit comments

Comments
 (0)