[postgis-tickets] r14657 - Ensure restored database is created the same as the initial one
Sandro Santilli
strk at keybit.net
Tue Feb 9 14:04:46 PST 2016
Author: strk
Date: 2016-02-09 14:04:46 -0800 (Tue, 09 Feb 2016)
New Revision: 14657
Modified:
trunk/regress/run_test.pl
Log:
Ensure restored database is created the same as the initial one
Fixes ORDER BY consistency, probably also with the loader tests
already tweaked to workaround this
See #3444
Modified: trunk/regress/run_test.pl
===================================================================
--- trunk/regress/run_test.pl 2016-02-09 18:20:56 UTC (rev 14656)
+++ trunk/regress/run_test.pl 2016-02-09 22:04:46 UTC (rev 14657)
@@ -1197,13 +1197,19 @@
##################################################################
# Create the spatial database
##################################################################
+sub create_db
+{
+ my $cmd = "createdb --encoding=UTF-8 --template=template0 --lc-collate=C $DB > $REGRESS_LOG";
+ return system($cmd);
+}
+
sub create_spatial
{
my ($cmd, $rv);
print "Creating database '$DB' \n";
- $cmd = "createdb --encoding=UTF-8 --template=template0 --lc-collate=C $DB > $REGRESS_LOG";
- $rv = system($cmd);
+ $rv = create_db();
+
$cmd = "createlang plpgsql $DB >> $REGRESS_LOG 2>&1";
$rv = system($cmd);
@@ -1529,7 +1535,7 @@
die;
}
- $rv = system("createdb ${DB} >> $REGRESS_LOG 2>&1");
+ $rv = create_db();
if ( $rv ) {
fail("Could not create ${DB}", $REGRESS_LOG);
die;
More information about the postgis-tickets
mailing list