mirror of https://github.com/citusdata/citus.git
Merge pull request #3425 from citusdata/make-test-copying-work-again
Replace denormalized test output with normalized at the end of the runpull/3428/head^2
commit
ca85b2b4ff
|
@ -0,0 +1,15 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
# This is to make the following command work to update the test output:
|
||||||
|
# cp src/test/regress/{results,expected}/multi_cluster_management.out
|
||||||
|
#
|
||||||
|
# This can not be done in the custom "diff" command, because that is executed
|
||||||
|
# multiple times
|
||||||
|
|
||||||
|
for modified_file in {results,expected}/*.modified; do
|
||||||
|
original=${modified_file%.modified}
|
||||||
|
mv "$original" "$original.unmodified"
|
||||||
|
mv "$modified_file" "$original"
|
||||||
|
done
|
|
@ -783,6 +783,8 @@ push(@arguments, @ARGV);
|
||||||
|
|
||||||
my $startTime = time();
|
my $startTime = time();
|
||||||
|
|
||||||
|
my $exitcode = 0;
|
||||||
|
|
||||||
# Finally run the tests
|
# Finally run the tests
|
||||||
if ($vanillatest)
|
if ($vanillatest)
|
||||||
{
|
{
|
||||||
|
@ -797,30 +799,33 @@ if ($vanillatest)
|
||||||
mkdir "./testtablespace";
|
mkdir "./testtablespace";
|
||||||
|
|
||||||
my $pgregressdir=catfile(dirname("$pgxsdir"), "regress");
|
my $pgregressdir=catfile(dirname("$pgxsdir"), "regress");
|
||||||
system("$plainRegress", ("--inputdir", $pgregressdir),
|
$exitcode = system("$plainRegress", ("--inputdir", $pgregressdir),
|
||||||
("--schedule", catfile("$pgregressdir", "parallel_schedule"))) == 0
|
("--schedule", catfile("$pgregressdir", "parallel_schedule")))
|
||||||
or die "Could not run vanilla tests";
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
system("make", ("-C", catfile("$postgresBuilddir", "src", "test", "regress"), "installcheck-parallel")) == 0
|
$exitcode = system("make", ("-C", catfile("$postgresBuilddir", "src", "test", "regress"), "installcheck-parallel"))
|
||||||
or die "Could not run vanilla tests";
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elsif ($isolationtester)
|
elsif ($isolationtester)
|
||||||
{
|
{
|
||||||
push(@arguments, "--dbname=regression");
|
push(@arguments, "--dbname=regression");
|
||||||
system("$isolationRegress", @arguments) == 0
|
$exitcode = system("$isolationRegress", @arguments)
|
||||||
or die "Could not run isolation tests";
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
system("$plainRegress", @arguments) == 0
|
$exitcode = system("$plainRegress", @arguments);
|
||||||
or die "Could not run regression tests";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
system (catfile("bin", "copy_modified"));
|
||||||
my $endTime = time();
|
my $endTime = time();
|
||||||
|
|
||||||
|
if ($exitcode == 0) {
|
||||||
print "Finished in ". ($endTime - $startTime)." seconds. \n";
|
print "Finished in ". ($endTime - $startTime)." seconds. \n";
|
||||||
|
|
||||||
exit 0;
|
exit 0;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
die "Failed in ". ($endTime - $startTime)." seconds. \n";
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue