[postgis-tickets] r17912 - Avoid sending two queries at once, to more easily spot actual errors

Sandro Santilli strk at kbt.io
Sun Oct 13 02:27:02 PDT 2019


Author: strk
Date: 2019-10-13 02:27:01 -0700 (Sun, 13 Oct 2019)
New Revision: 17912

Modified:
   trunk/regress/run_test.pl
Log:
Avoid sending two queries at once, to more easily spot actual errors

See #4530

Modified: trunk/regress/run_test.pl
===================================================================
--- trunk/regress/run_test.pl	2019-10-13 04:56:48 UTC (rev 17911)
+++ trunk/regress/run_test.pl	2019-10-13 09:27:01 UTC (rev 17912)
@@ -322,6 +322,13 @@
   {
     $query = "insert into upgrade_test(r) ";
     $query .= "select ST_AddBand(ST_MakeEmptyRaster(10, 10, 1, 1, 2, 2, 0, 0,4326), 1, '8BSI'::text, -129, NULL);";
+    $ret = sql($query);
+    unless ( $ret =~ /^INSERT/ ) {
+      `dropdb $DB`;
+      print "\nSomething went wrong inserting raster into upgrade_test table: $ret.\n";
+      exit(1);
+    }
+
     $query .= "set client_min_messages to error; select AddRasterConstraints('upgrade_test', 'r')";
     $ret = sql($query);
     unless ( $ret =~ /^t$/ ) {



More information about the postgis-tickets mailing list