diff --git a/release/schema-verifier/verify_deployed_sql_schema.sh b/release/schema-verifier/verify_deployed_sql_schema.sh index 563c513e4..b4e105565 100755 --- a/release/schema-verifier/verify_deployed_sql_schema.sh +++ b/release/schema-verifier/verify_deployed_sql_schema.sh @@ -69,6 +69,14 @@ PGPASSWORD=${db_password} pg_dump -h localhost -U "${db_user}" \ --exclude-table flyway_schema_history \ postgres +if [ $? -ne 0 ]; then + echo "Failed to dump schema." + exit 1 +else + echo "Schema dumped." +fi + + raw_diff=$(diff /schema/nomulus.golden.sql /schema/nomulus.actual.sql) # Clean up the raw_diff: # - Remove diff locations (e.g. "5,6c5,6): grep "^[<>]"