Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
use strict ;
use warnings ;
use Config ;
use PostgresNode ;
use TestLib ;
use Test::More ;
my $ tempdir = TestLib:: tempdir ;
my $ tempdir_short = TestLib:: tempdir_short ;
###############################################################
# Definition of the pg_dump runs to make.
#
# Each of these runs are named and those names are used below
# to define how each test should (or shouldn't) treat a result
# from a given run.
#
# test_key indicates that a given run should simply use the same
# set of like/unlike tests as another run, and which run that is.
#
# dump_cmd is the pg_dump command to run, which is an array of
# the full command and arguments to run. Note that this is run
# using $node->command_ok(), so the port does not need to be
# specified and is pulled from $PGPORT, which is set by the
# PostgresNode system.
#
# restore_cmd is the pg_restore command to run, if any. Note
# that this should generally be used when the pg_dump goes to
# a non-text file and that the restore can then be used to
# generate a text file to run through the tests from the
# non-text file generated by pg_dump.
#
# TODO: Have pg_restore actually restore to an independent
# database and then pg_dump *that* database (or something along
# those lines) to validate that part of the process.
my % pgdump_runs = (
binary_upgrade = > {
dump_cmd = > [
'pg_dump' ,
2017-01-31 18:42:16 +01:00
"--file=$tempdir/binary_upgrade.sql" ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'--schema-only' ,
'--binary-upgrade' ,
2016-06-12 10:19:56 +02:00
'-d' , 'postgres' , # alternative way to specify database
] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
clean = > {
dump_cmd = > [
'pg_dump' ,
2017-01-31 18:42:16 +01:00
"--file=$tempdir/clean.sql" ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'-c' ,
2016-06-12 10:19:56 +02:00
'-d' , 'postgres' , # alternative way to specify database
] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
clean_if_exists = > {
dump_cmd = > [
'pg_dump' ,
2017-01-31 18:42:16 +01:00
"--file=$tempdir/clean_if_exists.sql" ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'-c' ,
'--if-exists' ,
2017-01-31 18:42:16 +01:00
'--encoding=UTF8' , # no-op, just tests that option is accepted
2016-06-12 10:19:56 +02:00
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
column_inserts = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , "--file=$tempdir/column_inserts.sql" ,
'-a' , '--column-inserts' ,
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
createdb = > {
dump_cmd = > [
'pg_dump' ,
2017-01-31 18:42:16 +01:00
"--file=$tempdir/createdb.sql" ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'-C' ,
2017-01-31 18:42:16 +01:00
'-R' , # no-op, just for testing
2016-06-12 10:19:56 +02:00
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
data_only = > {
dump_cmd = > [
'pg_dump' ,
2017-01-31 18:42:16 +01:00
"--file=$tempdir/data_only.sql" ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'-a' ,
2017-01-31 18:42:16 +01:00
'-v' , # no-op, just make sure it works
2016-06-12 10:19:56 +02:00
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
defaults = > {
2016-06-12 10:19:56 +02:00
dump_cmd = > [ 'pg_dump' , '-f' , "$tempdir/defaults.sql" , 'postgres' , ] ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
} ,
defaults_custom_format = > {
test_key = > 'defaults' ,
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , '-Fc' , '-Z6' ,
"--file=$tempdir/defaults_custom_format.dump" , 'postgres' , ] ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
restore_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_restore' , '-Fc' ,
"--file=$tempdir/defaults_custom_format.sql" ,
2016-06-12 10:19:56 +02:00
"$tempdir/defaults_custom_format.dump" , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
defaults_dir_format = > {
test_key = > 'defaults' ,
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , '-Fd' ,
"--file=$tempdir/defaults_dir_format" , 'postgres' , ] ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
restore_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_restore' , '-Fd' ,
"--file=$tempdir/defaults_dir_format.sql" ,
2016-06-12 10:19:56 +02:00
"$tempdir/defaults_dir_format" , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
defaults_parallel = > {
test_key = > 'defaults' ,
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , '-Fd' , '-j2' , "--file=$tempdir/defaults_parallel" ,
2016-06-12 10:19:56 +02:00
'postgres' , ] ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
restore_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_restore' ,
"--file=$tempdir/defaults_parallel.sql" ,
"$tempdir/defaults_parallel" , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
defaults_tar_format = > {
test_key = > 'defaults' ,
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , '-Ft' ,
"--file=$tempdir/defaults_tar_format.tar" , 'postgres' , ] ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
restore_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_restore' , '-Ft' ,
"--file=$tempdir/defaults_tar_format.sql" ,
2016-06-12 10:19:56 +02:00
"$tempdir/defaults_tar_format.tar" , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , "--file=$tempdir/exclude_dump_test_schema.sql" ,
'--exclude-schema=dump_test' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' ,
"--file=$tempdir/exclude_test_table.sql" ,
'--exclude-table=dump_test.test_table' ,
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' ,
"--file=$tempdir/exclude_test_table_data.sql" ,
'--exclude-table-data=dump_test.test_table' ,
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
pg_dumpall_globals = > {
2017-01-31 18:42:16 +01:00
dump_cmd = > [
'pg_dumpall' , '-v' ,
"--file=$tempdir/pg_dumpall_globals.sql" , '-g' , ] , } ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dumpall' , "--file=$tempdir/pg_dumpall_globals_clean.sql" ,
'-g' , '-c' , ] , } ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > {
dump_cmd = >
2017-01-31 18:42:16 +01:00
[ 'pg_dumpall' , "--file=$tempdir/pg_dumpall_dbprivs.sql" , ] , } ,
2016-11-29 17:09:35 +01:00
no_blobs = > {
dump_cmd = >
2017-01-31 18:42:16 +01:00
[ 'pg_dump' , "--file=$tempdir/no_blobs.sql" , '-B' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
no_privs = > {
2016-06-12 10:19:56 +02:00
dump_cmd = >
2017-01-31 18:42:16 +01:00
[ 'pg_dump' , "--file=$tempdir/no_privs.sql" , '-x' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
no_owner = > {
2016-06-12 10:19:56 +02:00
dump_cmd = >
2017-01-31 18:42:16 +01:00
[ 'pg_dump' , "--file=$tempdir/no_owner.sql" , '-O' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
only_dump_test_schema = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , "--file=$tempdir/only_dump_test_schema.sql" ,
'--schema=dump_test' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
only_dump_test_table = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' ,
"--file=$tempdir/only_dump_test_table.sql" ,
'--table=dump_test.test_table' ,
'--lock-wait-timeout=1000000' ,
2016-06-12 10:19:56 +02:00
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
role = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' ,
"--file=$tempdir/role.sql" ,
2016-08-15 19:42:51 +02:00
'--role=regress_dump_test_role' ,
2017-01-31 18:42:16 +01:00
'--schema=dump_test_second_schema' ,
'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
schema_only = > {
2016-06-12 10:19:56 +02:00
dump_cmd = >
2017-01-31 18:42:16 +01:00
[ 'pg_dump' , "--file=$tempdir/schema_only.sql" , '-s' , 'postgres' , ] ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
} ,
section_pre_data = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , "--file=$tempdir/section_pre_data.sql" ,
2016-06-12 10:19:56 +02:00
'--section=pre-data' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
section_data = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , "--file=$tempdir/section_data.sql" ,
'--section=data' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
section_post_data = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , "--file=$tempdir/section_post_data.sql" ,
2016-06-12 10:19:56 +02:00
'--section=post-data' , 'postgres' , ] , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
test_schema_plus_blobs = > {
dump_cmd = > [
2017-01-31 18:42:16 +01:00
'pg_dump' , "--file=$tempdir/test_schema_plus_blobs.sql" ,
'--schema=dump_test' , '-b' , '-B' , 'postgres' , ] , } , ) ;
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
###############################################################
# Definition of the tests to run.
#
# Each test is defined using the log message that will be used.
#
# A regexp should be defined for each test which provides the
# basis for the test. That regexp will be run against the output
# file of each of the runs which the test is to be run against
# and the success of the result will depend on if the regexp
# result matches the expected 'like' or 'unlike' case.
#
# For each test, there are two sets of runs defined, one for
# the 'like' tests and one for the 'unlike' tests. 'like'
# essentially means "the regexp for this test must match the
# output file". 'unlike' is the opposite.
#
# There are a few 'catch-all' tests which can be used to have
# a single, simple, test to over a range of other tests. For
# example, there is a '^CREATE ' test, which is used for the
# 'data-only' test as there should never be any kind of CREATE
# statement in a 'data-only' run. Without the catch-all, we
# would have to list the 'data-only' run in each and every
# 'CREATE xxxx' test, which would be a lot of additional tests.
#
# Note that it makes no sense for the same run to ever be listed
# in both 'like' and 'unlike' categories.
#
# There can then be a 'create_sql' and 'create_order' for a
# given test. The 'create_sql' commands are collected up in
# 'create_order' and then run against the database prior to any
# of the pg_dump runs happening. This is what "seeds" the
# system with objects to be dumped out.
#
# Building of this hash takes a bit of time as all of the regexps
# included in it are compiled. This greatly improves performance
# as the regexps are used for each run the test applies to.
my % tests = (
2016-07-18 00:42:31 +02:00
'ALTER DEFAULT PRIVILEGES FOR ROLE regress_dump_test_role' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 14 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' ALTER DEFAULT PRIVILEGES
2016-07-18 00:42:31 +02:00
FOR ROLE regress_dump_test_role IN SCHEMA dump_test
GRANT SELECT ON TABLES TO regress_dump_test_role ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
\ QALTER DEFAULT PRIVILEGES \ E
2016-07-18 00:42:31 +02:00
\ QFOR ROLE regress_dump_test_role IN SCHEMA dump_test \ E
\ QGRANT SELECT ON TABLES TO regress_dump_test_role ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-11-18 20:21:33 +01:00
no_owner = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_pre_data = > 1 ,
section_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-07-18 00:42:31 +02:00
'ALTER ROLE regress_dump_test_role' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QALTER ROLE regress_dump_test_role WITH \ E
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QNOSUPERUSER INHERIT NOCREATEROLE NOCREATEDB NOLOGIN \ E
\ QNOREPLICATION NOBYPASSRLS ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
2016-06-12 10:19:56 +02:00
createdb = > 1 ,
2016-11-18 20:21:33 +01:00
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER FUNCTION dump_test.pltestlang_call_handler() OWNER TO' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
catch_all = >
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
\ QALTER FUNCTION dump_test . pltestlang_call_handler ( ) \ E
\ QOWNER TO \ E
2016-05-07 22:36:50 +02:00
. * ; / xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
only_dump_test_table = > 1 ,
role = > 1 , } , } ,
'ALTER LARGE OBJECT ... OWNER TO' = > {
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr/^ALTER LARGE OBJECT \d+ OWNER TO .*;/ m ,
like = > {
2016-11-18 20:21:33 +01:00
clean = > 1 ,
clean_if_exists = > 1 ,
column_inserts = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
no_privs = > 1 ,
pg_dumpall_dbprivs = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-11-18 20:21:33 +01:00
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
schema_only = > 1 ,
section_data = > 1 ,
section_post_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER PROCEDURAL LANGUAGE pltestlang OWNER TO' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
catch_all = >
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^ALTER PROCEDURAL LANGUAGE pltestlang OWNER TO .*;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER SCHEMA dump_test OWNER TO' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
catch_all = >
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^ALTER SCHEMA dump_test OWNER TO .*;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
only_dump_test_table = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER SCHEMA dump_test_second_schema OWNER TO' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
catch_all = >
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^ALTER SCHEMA dump_test_second_schema OWNER TO .*;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-07-31 16:57:15 +02:00
'ALTER SEQUENCE test_table_col1_seq' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
2016-07-31 16:57:15 +02:00
\ QALTER SEQUENCE test_table_col1_seq OWNED BY test_table . col1 ; \ E
/ xm ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-07-31 16:57:15 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_dbprivs = > 1 ,
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
2017-01-31 18:42:16 +01:00
data_only = > 1 ,
2016-07-31 16:57:15 +02:00
exclude_test_table = > 1 ,
exclude_dump_test_schema = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-07-31 16:57:15 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-07-31 16:57:15 +02:00
'ALTER SEQUENCE test_third_table_col1_seq' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
2016-07-31 16:57:15 +02:00
\ QALTER SEQUENCE test_third_table_col1_seq OWNED BY test_third_table . col1 ; \ E
/ xm ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-07-31 16:57:15 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-07-31 16:57:15 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-07-31 16:57:15 +02:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-07-31 16:57:15 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER TABLE ONLY test_table ADD CONSTRAINT ... PRIMARY KEY' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'ALTER TABLE ... commands' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QALTER TABLE ONLY test_table \ E \ n ^ \ s +
\ QADD CONSTRAINT test_table_pkey PRIMARY KEY ( col1 ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
2016-11-18 20:21:33 +01:00
no_owner = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
exclude_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_pre_data = > 1 ,
section_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER TABLE test_table OWNER TO' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
catch_all = >
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^ALTER TABLE test_table OWNER TO .*;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
exclude_test_table = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER TABLE test_table ENABLE ROW LEVEL SECURITY' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'ALTER TABLE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 23 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' ALTER TABLE dump_test . test_table
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
ENABLE ROW LEVEL SECURITY ; ' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^ALTER TABLE test_table ENABLE ROW LEVEL SECURITY;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
2016-11-18 20:21:33 +01:00
no_owner = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
section_pre_data = > 1 ,
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
exclude_test_table = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER TABLE test_second_table OWNER TO' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
catch_all = >
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^ALTER TABLE test_second_table OWNER TO .*;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
only_dump_test_table = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'ALTER TABLE test_third_table OWNER TO' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
catch_all = >
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^ALTER TABLE test_third_table OWNER TO .*;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2017-01-19 18:00:00 +01:00
# catch-all for ALTER ... OWNER (except LARGE OBJECTs and PUBLICATIONs)
'ALTER ... OWNER commands (except LARGE OBJECTs and PUBLICATIONs)' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
2017-01-19 18:00:00 +01:00
regexp = > qr/^ALTER (?!LARGE OBJECT|PUBLICATION)(.*) OWNER TO .*;/ m ,
2017-01-31 18:42:16 +01:00
like = > { } , # use more-specific options above
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
no_owner = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
section_data = > 1 ,
section_post_data = > 1 , } , } ,
2016-06-12 10:19:56 +02:00
2016-11-18 20:21:33 +01:00
# catch-all for ALTER TABLE ... (except OWNER TO)
2016-05-25 05:31:55 +02:00
'ALTER TABLE ... commands' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^ALTER TABLE .* (?!OWNER TO)(.*);/ m ,
like = > { } , # use more-specific options above
2016-05-25 05:31:55 +02:00
unlike = > {
2016-06-12 10:19:56 +02:00
column_inserts = > 1 ,
data_only = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-06-12 10:19:56 +02:00
section_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
'BLOB create (using lo_from_bytea)' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
create_order = > 50 ,
2017-01-31 18:42:16 +01:00
create_sql = >
'SELECT pg_catalog.lo_from_bytea(0, \'\\x310a320a330a340a350a360a370a380a390a\');' ,
2016-11-18 20:21:33 +01:00
regexp = > qr/^SELECT pg_catalog\.lo_create\('\d+'\);/ m ,
2017-01-31 18:42:16 +01:00
like = > {
clean = > 1 ,
clean_if_exists = > 1 ,
column_inserts = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
no_privs = > 1 ,
no_owner = > 1 ,
pg_dumpall_dbprivs = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
no_blobs = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
schema_only = > 1 ,
section_data = > 1 ,
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
'BLOB load (using lo_from_bytea)' = > {
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
2016-11-18 20:21:33 +01:00
\ QSELECT pg_catalog . lo_open \ E \ ( '\d+' , \ \ d + \ ) ; \ n
\ QSELECT pg_catalog . lowrite ( 0 , \ E
\ Q '\x310a320a330a340a350a360a370a380a390a' ) ; \ E \ n
\ QSELECT pg_catalog . lo_close ( 0 ) ; \ E
/ xm ,
like = > {
2017-01-31 18:42:16 +01:00
clean = > 1 ,
clean_if_exists = > 1 ,
column_inserts = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
data_only = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
no_owner = > 1 ,
no_privs = > 1 ,
pg_dumpall_dbprivs = > 1 ,
section_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
no_blobs = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
schema_only = > 1 ,
section_pre_data = > 1 ,
section_post_data = > 1 , } , } ,
2016-06-12 10:19:56 +02:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COMMENT ON DATABASE postgres' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'COMMENT commands' ,
2017-01-31 18:42:16 +01:00
regexp = > qr/^COMMENT ON DATABASE postgres IS .*;/ m ,
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2017-01-31 18:42:16 +01:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
role = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COMMENT ON EXTENSION plpgsql' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'COMMENT commands' ,
2017-01-31 18:42:16 +01:00
regexp = > qr/^COMMENT ON EXTENSION plpgsql IS .*;/ m ,
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2017-01-31 18:42:16 +01:00
binary_upgrade = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
role = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COMMENT ON TABLE dump_test.test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'COMMENT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 36 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' COMMENT ON TABLE dump_test . test_table
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
IS \ 'comment on table\';' ,
2016-05-07 22:36:50 +02:00
regexp = > qr/^COMMENT ON TABLE test_table IS 'comment on table';/ m ,
2016-06-12 10:19:56 +02:00
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
2016-11-18 20:21:33 +01:00
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
2016-06-12 10:19:56 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
exclude_test_table = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COMMENT ON COLUMN dump_test.test_table.col1' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'COMMENT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 36 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' COMMENT ON COLUMN dump_test . test_table . col1
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
IS \ 'comment on column\';' ,
regexp = > qr / ^
\ QCOMMENT ON COLUMN test_table . col1 IS 'comment on column' ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
2016-11-18 20:21:33 +01:00
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
exclude_test_table = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COMMENT ON COLUMN dump_test.composite.f1' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'COMMENT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 44 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' COMMENT ON COLUMN dump_test . composite . f1
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
IS \ 'comment on column of type\';' ,
regexp = > qr / ^
\ QCOMMENT ON COLUMN composite . f1 IS 'comment on column of type' ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
2016-11-18 20:21:33 +01:00
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
only_dump_test_table = > 1 ,
role = > 1 , } , } ,
2016-06-12 10:19:56 +02:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
# catch-all for COMMENTs
'COMMENT commands' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^COMMENT ON / m ,
like = > { } , # use more-specific options above
unlike = > {
2016-06-12 10:19:56 +02:00
column_inserts = > 1 ,
data_only = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-06-12 10:19:56 +02:00
section_data = > 1 ,
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COPY test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'COPY ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 4 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'INSERT INTO dump_test.test_table (col1) '
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
. 'SELECT generate_series FROM generate_series(1,9);' ,
regexp = > qr / ^
\ QCOPY test_table ( col1 ) FROM stdin ; \ E
\ n ( ? : \ d \ n ) { 9 } \ \ \ . \ n
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
section_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
exclude_test_table_data = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COPY fk_reference_test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'COPY ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 22 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'INSERT INTO dump_test.fk_reference_test_table (col1) '
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
. 'SELECT generate_series FROM generate_series(1,5);' ,
regexp = > qr / ^
\ QCOPY fk_reference_test_table ( col1 ) FROM stdin ; \ E
\ n ( ? : \ d \ n ) { 5 } \ \ \ . \ n
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
section_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
only_dump_test_table = > 1 ,
role = > 1 , } , } ,
# In a data-only dump, we do try to actually order according to FKs,
# so this check is just making sure that the referring table comes after
# the referred-to table.
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COPY fk_reference_test_table second' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # really only for data-only
2016-11-18 20:21:33 +01:00
catch_all = > 'COPY ... commands' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QCOPY test_table ( col1 ) FROM stdin ; \ E
\ n ( ? : \ d \ n ) { 9 } \ \ \ . \ n . *
\ QCOPY fk_reference_test_table ( col1 ) FROM stdin ; \ E
\ n ( ? : \ d \ n ) { 5 } \ \ \ . \ n
2016-05-07 22:36:50 +02:00
/ xms ,
2016-06-12 10:19:56 +02:00
like = > { data_only = > 1 , } ,
2017-01-31 18:42:16 +01:00
unlike = > { } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COPY test_second_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'COPY ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 7 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'INSERT INTO dump_test.test_second_table (col1, col2) '
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
. 'SELECT generate_series, generate_series::text '
. 'FROM generate_series(1,9);' ,
regexp = > qr / ^
\ QCOPY test_second_table ( col1 , col2 ) FROM stdin ; \ E
\ n ( ? : \ d \ t \ d \ n ) { 9 } \ \ \ . \ n
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
section_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-11-18 20:21:33 +01:00
only_dump_test_table = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'COPY test_third_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'COPY ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 12 ,
create_sql = >
2016-06-12 10:19:56 +02:00
'INSERT INTO dump_test_second_schema.test_third_table (col1) '
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
. 'SELECT generate_series FROM generate_series(1,9);' ,
regexp = > qr / ^
\ QCOPY test_third_table ( col1 ) FROM stdin ; \ E
\ n ( ? : \ d \ n ) { 9 } \ \ \ . \ n
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
'COPY ... commands' = > { # catch-all for COPY
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^COPY / m ,
like = > { } , # use more-specific options above
unlike = > {
2016-11-18 20:21:33 +01:00
binary_upgrade = > 1 ,
column_inserts = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
schema_only = > 1 ,
section_pre_data = > 1 ,
section_post_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'INSERT INTO test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'INSERT INTO ...' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
( ? : INSERT \ INTO \ test_table \ \ ( col1 \ ) \ VALUES \ \ ( \ d \ ) ; \ n ) { 9 }
2016-05-07 22:36:50 +02:00
/ xm ,
2016-06-12 10:19:56 +02:00
like = > { column_inserts = > 1 , } ,
2017-01-31 18:42:16 +01:00
unlike = > { } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'INSERT INTO test_second_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'INSERT INTO ...' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
( ? : INSERT \ INTO \ test_second_table \ \ ( col1 , \ col2 \ )
2016-05-07 22:36:50 +02:00
\ VALUES \ \ ( \ d , \ '\d' \ ) ; \ n ) { 9 } / xm ,
2016-06-12 10:19:56 +02:00
like = > { column_inserts = > 1 , } ,
2017-01-31 18:42:16 +01:00
unlike = > { } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'INSERT INTO test_third_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'INSERT INTO ...' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
( ? : INSERT \ INTO \ test_third_table \ \ ( col1 \ )
2016-05-07 22:36:50 +02:00
\ VALUES \ \ ( \ d \ ) ; \ n ) { 9 } / xm ,
2016-06-12 10:19:56 +02:00
like = > { column_inserts = > 1 , } ,
2017-01-31 18:42:16 +01:00
unlike = > { } , } ,
2016-11-18 20:21:33 +01:00
# INSERT INTO catch-all
'INSERT INTO ...' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^INSERT INTO .* VALUES .*;/ xm ,
like = > { } , # use more-specific options above
2016-06-12 10:19:56 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
binary_upgrade = > 1 ,
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
2016-06-12 10:19:56 +02:00
section_data = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
2016-11-18 20:21:33 +01:00
section_pre_data = > 1 ,
section_data = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-07-18 00:42:31 +02:00
'CREATE ROLE regress_dump_test_role' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 1 ,
2016-07-18 00:42:31 +02:00
create_sql = > 'CREATE ROLE regress_dump_test_role;' ,
regexp = > qr/^CREATE ROLE regress_dump_test_role;/ m ,
2016-06-12 10:19:56 +02:00
like = > {
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
2016-06-12 10:19:56 +02:00
createdb = > 1 ,
2016-11-18 20:21:33 +01:00
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-12-21 19:47:06 +01:00
'CREATE CAST FOR timestamptz' = > {
create_order = > 51 ,
2017-01-31 18:42:16 +01:00
create_sql = >
'CREATE CAST (timestamptz AS interval) WITH FUNCTION age(timestamptz) AS ASSIGNMENT;' ,
regexp = >
qr/CREATE CAST \(timestamp with time zone AS interval\) WITH FUNCTION pg_catalog\.age\(timestamp with time zone\) AS ASSIGNMENT;/ m ,
2016-12-21 19:47:06 +01:00
like = > {
2017-01-31 18:42:16 +01:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
2016-12-21 19:47:06 +01:00
exclude_dump_test_schema = > 1 ,
2017-01-31 18:42:16 +01:00
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
no_blobs = > 1 ,
no_privs = > 1 ,
no_owner = > 1 ,
2016-12-21 19:47:06 +01:00
pg_dumpall_dbprivs = > 1 ,
2017-01-31 18:42:16 +01:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
section_post_data = > 1 ,
2016-12-21 19:47:06 +01:00
test_schema_plus_blobs = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE DATABASE postgres' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QCREATE DATABASE postgres WITH TEMPLATE = template0 \ E
2016-05-07 22:36:50 +02:00
. * ; / xm ,
2016-06-12 10:19:56 +02:00
like = > { createdb = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-07-17 15:04:46 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-07-17 15:04:46 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-07-17 15:04:46 +02:00
'CREATE DATABASE dump_test' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-07-17 15:04:46 +02:00
create_order = > 47 ,
2016-08-15 19:42:51 +02:00
create_sql = > 'CREATE DATABASE dump_test;' ,
regexp = > qr / ^
2016-07-17 15:04:46 +02:00
\ QCREATE DATABASE dump_test WITH TEMPLATE = template0 \ E
. * ; / xm ,
like = > { pg_dumpall_dbprivs = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
2016-07-17 15:04:46 +02:00
createdb = > 1 ,
2016-11-18 20:21:33 +01:00
data_only = > 1 ,
2016-07-17 15:04:46 +02:00
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-07-17 15:04:46 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-06-12 10:19:56 +02:00
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE EXTENSION ... plpgsql' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QCREATE EXTENSION IF NOT EXISTS plpgsql WITH SCHEMA pg_catalog ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE AGGREGATE dump_test.newavg' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 25 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE AGGREGATE dump_test . newavg (
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
sfunc = int4_avg_accum ,
basetype = int4 ,
stype = _int8 ,
finalfunc = int8_avg ,
initcond1 = \ ' { 0 , 0 } \ '
) ; ' ,
regexp = > qr / ^
\ QCREATE AGGREGATE newavg ( integer ) ( \ E
\ n \ s + \ QSFUNC = int4_avg_accum , \ E
\ n \ s + \ QSTYPE = bigint [] , \ E
\ n \ s + \ QINITCOND = '{0,0}' , \ E
\ n \ s + \ QFINALFUNC = int8_avg \ E
2016-05-07 22:36:50 +02:00
\ n \ ) ; / xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE DOMAIN dump_test.us_postal_code' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 29 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE DOMAIN dump_test . us_postal_code AS TEXT
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
CHECK ( VALUE ~ \ ' ^ \ d { 5 } $\ ' OR
VALUE ~ \ '^\d{5}-\d{4}$\');' ,
regexp = > qr / ^
\ QCREATE DOMAIN us_postal_code AS text \ E
\ n \ s +
\ QCONSTRAINT us_postal_code_check CHECK \ E
\ Q ( ( ( VALUE ~ ' ^ \ d { 5 } \ E
\ $ \ Q '::text) OR (VALUE ~ ' ^ \ d { 5 } - \ d { 4 } \ E \ $
\ Q ' :: text ) ) ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE FUNCTION dump_test.pltestlang_call_handler' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 17 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE FUNCTION dump_test . pltestlang_call_handler ( )
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
RETURNS LANGUAGE_HANDLER AS \ ' $ libdir / plpgsql \ ' ,
\ 'plpgsql_call_handler\' LANGUAGE C;' ,
regexp = > qr / ^
\ QCREATE FUNCTION pltestlang_call_handler ( ) \ E
\ QRETURNS language_handler \ E
\ n \ s + \ QLANGUAGE c \ E
\ n \ s + AS \ \ ' \ $
\ Qlibdir \ / plpgsql ', ' plpgsql_call_handler ' ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE FUNCTION dump_test.trigger_func' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 30 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE FUNCTION dump_test . trigger_func ( )
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
RETURNS trigger LANGUAGE plpgsql
AS $$ BEGIN RETURN NULL ; END ; $$ ; ' ,
regexp = > qr / ^
\ QCREATE FUNCTION trigger_func ( ) RETURNS trigger \ E
\ n \ s + \ QLANGUAGE plpgsql \ E
\ n \ s + AS \ \ $\ $
\ Q BEGIN RETURN NULL ; END ; \ E
2016-05-07 22:36:50 +02:00
\ $\ $; / xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE FUNCTION dump_test.event_trigger_func' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 32 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE FUNCTION dump_test . event_trigger_func ( )
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
RETURNS event_trigger LANGUAGE plpgsql
AS $$ BEGIN RETURN ; END ; $$ ; ' ,
regexp = > qr / ^
\ QCREATE FUNCTION event_trigger_func ( ) RETURNS event_trigger \ E
\ n \ s + \ QLANGUAGE plpgsql \ E
\ n \ s + AS \ \ $\ $
\ Q BEGIN RETURN ; END ; \ E
2016-05-07 22:36:50 +02:00
\ $\ $; / xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE EVENT TRIGGER test_event_trigger' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 33 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE EVENT TRIGGER test_event_trigger
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
ON ddl_command_start
EXECUTE PROCEDURE dump_test . event_trigger_func ( ) ; ' ,
regexp = > qr / ^
\ QCREATE EVENT TRIGGER test_event_trigger \ E
\ QON ddl_command_start \ E
\ n \ s + \ QEXECUTE PROCEDURE dump_test . event_trigger_func ( ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
section_pre_data = > 1 ,
2016-06-12 10:19:56 +02:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TRIGGER test_trigger' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 31 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TRIGGER test_trigger
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
BEFORE INSERT ON dump_test . test_table
FOR EACH ROW WHEN ( NEW . col1 > 10 )
EXECUTE PROCEDURE dump_test . trigger_func ( ) ; ' ,
regexp = > qr / ^
\ QCREATE TRIGGER test_trigger BEFORE INSERT ON test_table \ E
\ QFOR EACH ROW WHEN ( ( new . col1 > 10 ) ) \ E
\ QEXECUTE PROCEDURE trigger_func ( ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_data = > 1 ,
section_pre_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TYPE dump_test.planets AS ENUM' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 37 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TYPE dump_test . planets
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
AS ENUM ( \ 'venus\', \'earth\', \'mars\' );' ,
regexp = > qr / ^
\ QCREATE TYPE planets AS ENUM ( \ E
\ n \ s + 'venus' ,
\ n \ s + 'earth' ,
\ n \ s + 'mars'
2016-05-07 22:36:50 +02:00
\ n \ ) ; / xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
binary_upgrade = > 1 ,
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TYPE dump_test.planets AS ENUM pg_upgrade' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QCREATE TYPE planets AS ENUM ( \ E
\ n \ ) ; . * ^
\ QALTER TYPE dump_test . planets ADD VALUE 'venus' ; \ E
\ n . * ^
\ QALTER TYPE dump_test . planets ADD VALUE 'earth' ; \ E
\ n . * ^
\ QALTER TYPE dump_test . planets ADD VALUE 'mars' ; \ E
2016-05-07 22:36:50 +02:00
\ n / xms ,
2016-06-12 10:19:56 +02:00
like = > { binary_upgrade = > 1 , } ,
unlike = > {
clean = > 1 ,
clean_if_exists = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
2016-06-12 10:19:56 +02:00
createdb = > 1 ,
2016-11-18 20:21:33 +01:00
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
defaults = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 ,
exclude_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
section_pre_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TYPE dump_test.textrange AS RANGE' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 38 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TYPE dump_test . textrange
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
AS RANGE ( subtype = text , collation = "C" ) ; ' ,
regexp = > qr / ^
\ QCREATE TYPE textrange AS RANGE ( \ E
\ n \ s + \ Qsubtype = text , \ E
\ n \ s + \ Qcollation = pg_catalog . "C" \ E
\ n \ ) ; / xm ,
like = > {
2016-11-18 20:21:33 +01:00
binary_upgrade = > 1 ,
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TYPE dump_test.int42' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 39 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'CREATE TYPE dump_test.int42;' ,
regexp = > qr/^CREATE TYPE int42;/ m ,
like = > {
2016-11-18 20:21:33 +01:00
binary_upgrade = > 1 ,
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
exclude_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE FUNCTION dump_test.int42_in' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 40 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE FUNCTION dump_test . int42_in ( cstring )
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
RETURNS dump_test . int42 AS \ ' int4in \ '
LANGUAGE internal STRICT IMMUTABLE ; ' ,
regexp = > qr / ^
\ QCREATE FUNCTION int42_in ( cstring ) RETURNS int42 \ E
\ n \ s + \ QLANGUAGE internal IMMUTABLE STRICT \ E
\ n \ s + AS \ \ $\ $ int4in \ $\ $;
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE FUNCTION dump_test.int42_out' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 41 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE FUNCTION dump_test . int42_out ( dump_test . int42 )
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
RETURNS cstring AS \ ' int4out \ '
LANGUAGE internal STRICT IMMUTABLE ; ' ,
regexp = > qr / ^
\ QCREATE FUNCTION int42_out ( int42 ) RETURNS cstring \ E
\ n \ s + \ QLANGUAGE internal IMMUTABLE STRICT \ E
\ n \ s + AS \ \ $\ $ int4out \ $\ $;
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TYPE dump_test.int42 populated' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 42 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TYPE dump_test . int42 (
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
internallength = 4 ,
input = dump_test . int42_in ,
output = dump_test . int42_out ,
alignment = int4 ,
default = 42 ,
passedbyvalue ) ; ' ,
regexp = > qr / ^
\ QCREATE TYPE int42 ( \ E
\ n \ s + \ QINTERNALLENGTH = 4 , \ E
\ n \ s + \ QINPUT = int42_in , \ E
\ n \ s + \ QOUTPUT = int42_out , \ E
\ n \ s + \ QDEFAULT = '42' , \ E
\ n \ s + \ QALIGNMENT = int4 , \ E
\ n \ s + \ QSTORAGE = plain , \ E
\ n \ s + PASSEDBYVALUE \ n \ ) ;
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-11-18 20:21:33 +01:00
binary_upgrade = > 1 ,
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TYPE dump_test.composite' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 43 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TYPE dump_test . composite AS (
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
f1 int ,
f2 dump_test . int42
) ; ' ,
regexp = > qr / ^
\ QCREATE TYPE composite AS ( \ E
\ n \ s + \ Qf1 integer , \ E
\ n \ s + \ Qf2 int42 \ E
\ n \ ) ;
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-11-18 20:21:33 +01:00
binary_upgrade = > 1 ,
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE FOREIGN DATA WRAPPER dummy' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 35 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'CREATE FOREIGN DATA WRAPPER dummy;' ,
regexp = > qr/CREATE FOREIGN DATA WRAPPER dummy;/ m ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE SERVER s1 FOREIGN DATA WRAPPER dummy' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 36 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'CREATE SERVER s1 FOREIGN DATA WRAPPER dummy;' ,
regexp = > qr/CREATE SERVER s1 FOREIGN DATA WRAPPER dummy;/ m ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-12-21 19:47:06 +01:00
'CREATE TRANSFORM FOR int' = > {
create_order = > 34 ,
2017-01-31 18:42:16 +01:00
create_sql = >
'CREATE TRANSFORM FOR int LANGUAGE SQL (FROM SQL WITH FUNCTION varchar_transform(internal), TO SQL WITH FUNCTION int4recv(internal));' ,
regexp = >
qr/CREATE TRANSFORM FOR integer LANGUAGE sql \(FROM SQL WITH FUNCTION pg_catalog\.varchar_transform\(internal\), TO SQL WITH FUNCTION pg_catalog\.int4recv\(internal\)\);/ m ,
2016-12-21 19:47:06 +01:00
like = > {
2017-01-31 18:42:16 +01:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
2016-12-21 19:47:06 +01:00
exclude_dump_test_schema = > 1 ,
2017-01-31 18:42:16 +01:00
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
no_blobs = > 1 ,
no_privs = > 1 ,
no_owner = > 1 ,
2016-12-21 19:47:06 +01:00
pg_dumpall_dbprivs = > 1 ,
2017-01-31 18:42:16 +01:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
section_post_data = > 1 ,
2016-12-21 19:47:06 +01:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE LANGUAGE pltestlang' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 18 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE LANGUAGE pltestlang
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
HANDLER dump_test . pltestlang_call_handler ; ' ,
regexp = > qr / ^
\ QCREATE PROCEDURAL LANGUAGE pltestlang \ E
\ QHANDLER pltestlang_call_handler ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
only_dump_test_schema = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE MATERIALIZED VIEW matview' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 20 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE MATERIALIZED VIEW dump_test . matview ( col1 ) AS
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
SELECT * FROM dump_test . test_table ; ' ,
regexp = > qr / ^
\ QCREATE MATERIALIZED VIEW matview AS \ E
\ n \ s + \ QSELECT test_table . col1 \ E
\ n \ s + \ QFROM test_table \ E
\ n \ s + \ QWITH NO DATA ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE MATERIALIZED VIEW matview_second' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 21 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE MATERIALIZED VIEW
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
dump_test . matview_second ( col1 ) AS
SELECT * FROM dump_test . matview ; ' ,
regexp = > qr / ^
\ QCREATE MATERIALIZED VIEW matview_second AS \ E
\ n \ s + \ QSELECT matview . col1 \ E
\ n \ s + \ QFROM matview \ E
\ n \ s + \ QWITH NO DATA ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE POLICY p1 ON test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 22 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE POLICY p1 ON dump_test . test_table
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
USING ( true )
WITH CHECK ( true ) ; ' ,
regexp = > qr / ^
2016-12-05 21:50:55 +01:00
\ QCREATE POLICY p1 ON test_table \ E
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QUSING ( true ) WITH CHECK ( true ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_pre_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE POLICY p2 ON test_table FOR SELECT' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 24 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE POLICY p2 ON dump_test . test_table
2016-07-18 00:42:31 +02:00
FOR SELECT TO regress_dump_test_role USING ( true ) ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QCREATE POLICY p2 ON test_table FOR SELECT TO regress_dump_test_role \ E
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QUSING ( true ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_pre_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE POLICY p3 ON test_table FOR INSERT' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 25 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE POLICY p3 ON dump_test . test_table
2016-07-18 00:42:31 +02:00
FOR INSERT TO regress_dump_test_role WITH CHECK ( true ) ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
\ QCREATE POLICY p3 ON test_table FOR INSERT \ E
2016-07-18 00:42:31 +02:00
\ QTO regress_dump_test_role WITH CHECK ( true ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_pre_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE POLICY p4 ON test_table FOR UPDATE' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 26 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE POLICY p4 ON dump_test . test_table FOR UPDATE
2016-07-18 00:42:31 +02:00
TO regress_dump_test_role USING ( true ) WITH CHECK ( true ) ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QCREATE POLICY p4 ON test_table FOR UPDATE TO regress_dump_test_role \ E
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QUSING ( true ) WITH CHECK ( true ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_pre_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE POLICY p5 ON test_table FOR DELETE' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 27 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE POLICY p5 ON dump_test . test_table
2016-07-18 00:42:31 +02:00
FOR DELETE TO regress_dump_test_role USING ( true ) ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
\ QCREATE POLICY p5 ON test_table FOR DELETE \ E
2016-07-18 00:42:31 +02:00
\ QTO regress_dump_test_role USING ( true ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_pre_data = > 1 , } , } ,
2016-12-05 21:50:55 +01:00
'CREATE POLICY p6 ON test_table AS RESTRICTIVE' = > {
create_order = > 27 ,
2017-01-31 18:42:16 +01:00
create_sql = > ' CREATE POLICY p6 ON dump_test . test_table AS RESTRICTIVE
2016-12-05 21:50:55 +01:00
USING ( false ) ; ' ,
regexp = > qr / ^
\ QCREATE POLICY p6 ON test_table AS RESTRICTIVE \ E
\ QUSING ( false ) ; \ E
/ xm ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_dbprivs = > 1 ,
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
2017-01-31 18:42:16 +01:00
section_pre_data = > 1 , } , } ,
2017-01-19 18:00:00 +01:00
'CREATE PUBLICATION pub1' = > {
create_order = > 50 ,
create_sql = > 'CREATE PUBLICATION pub1;' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
2017-01-19 18:00:00 +01:00
\ QCREATE PUBLICATION pub1 WITH ( PUBLISH INSERT , PUBLISH UPDATE , PUBLISH DELETE ) ; \ E
/ xm ,
like = > {
2017-01-31 18:42:16 +01:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2017-01-19 18:00:00 +01:00
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
2017-01-31 18:42:16 +01:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_dbprivs = > 1 ,
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
2017-01-19 18:00:00 +01:00
unlike = > {
section_pre_data = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
'ALTER PUBLICATION pub1 ADD TABLE test_table' = > {
create_order = > 51 ,
2017-01-31 18:42:16 +01:00
create_sql = >
'ALTER PUBLICATION pub1 ADD TABLE dump_test.test_table;' ,
2017-01-19 18:00:00 +01:00
regexp = > qr / ^
\ QALTER PUBLICATION pub1 ADD TABLE test_table ; \ E
/ xm ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_dbprivs = > 1 ,
schema_only = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
section_pre_data = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE SCHEMA dump_test' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 2 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'CREATE SCHEMA dump_test;' ,
regexp = > qr/^CREATE SCHEMA dump_test;/ m ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE SCHEMA dump_test_second_schema' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 9 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'CREATE SCHEMA dump_test_second_schema;' ,
regexp = > qr/^CREATE SCHEMA dump_test_second_schema;/ m ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TABLE test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 3 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TABLE dump_test . test_table (
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
col1 serial primary key ,
CHECK ( col1 <= 1000 )
) ; ' ,
regexp = > qr / ^
\ QCREATE TABLE test_table ( \ E
\ n \ s + \ Qcol1 integer NOT NULL , \ E
\ n \ s + \ QCONSTRAINT test_table_col1_check CHECK \ E
\ Q ( ( col1 <= 1000 ) ) \ E
2016-05-07 22:36:50 +02:00
\ n \ ) ; / xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
exclude_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TABLE fk_reference_test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 21 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TABLE dump_test . fk_reference_test_table (
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
col1 int primary key references dump_test . test_table
) ; ' ,
regexp = > qr / ^
\ QCREATE TABLE fk_reference_test_table ( \ E
\ n \ s + \ Qcol1 integer NOT NULL \ E
\ n \ ) ;
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TABLE test_second_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 6 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE TABLE dump_test . test_second_table (
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
col1 int ,
col2 text
) ; ' ,
regexp = > qr / ^
\ QCREATE TABLE test_second_table ( \ E
\ n \ s + \ Qcol1 integer , \ E
\ n \ s + \ Qcol2 text \ E
\ n \ ) ;
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE TABLE test_third_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 11 ,
create_sql = > ' CREATE TABLE dump_test_second_schema . test_third_table (
col1 serial
) ; ' ,
regexp = > qr / ^
\ QCREATE TABLE test_third_table ( \ E
\ n \ s + \ Qcol1 integer NOT NULL \ E
\ n \ ) ;
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE SEQUENCE test_table_col1_seq' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'CREATE ... commands' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QCREATE SEQUENCE test_table_col1_seq \ E
\ n \ s + \ QSTART WITH 1 \ E
\ n \ s + \ QINCREMENT BY 1 \ E
\ n \ s + \ QNO MINVALUE \ E
\ n \ s + \ QNO MAXVALUE \ E
\ n \ s + \ QCACHE 1 ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE SEQUENCE test_third_table_col1_seq' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'CREATE ... commands' ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QCREATE SEQUENCE test_third_table_col1_seq \ E
\ n \ s + \ QSTART WITH 1 \ E
\ n \ s + \ QINCREMENT BY 1 \ E
\ n \ s + \ QNO MINVALUE \ E
\ n \ s + \ QNO MAXVALUE \ E
\ n \ s + \ QCACHE 1 ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-06-12 10:19:56 +02:00
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'CREATE UNIQUE INDEX test_third_table_idx ON test_third_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'CREATE ... commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 13 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' CREATE UNIQUE INDEX test_third_table_idx
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
ON dump_test_second_schema . test_third_table ( col1 ) ; ' ,
regexp = > qr / ^
\ QCREATE UNIQUE INDEX test_third_table_idx \ E
\ QON test_third_table USING btree ( col1 ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_post_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-05-25 05:31:55 +02:00
pg_dumpall_globals_clean = > 1 ,
2016-11-18 20:21:33 +01:00
section_pre_data = > 1 ,
2016-06-12 10:19:56 +02:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-06-12 10:19:56 +02:00
'CREATE ... commands' = > { # catch-all for CREATE
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^CREATE / m ,
like = > { } , # use more-specific options above
unlike = > {
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
column_inserts = > 1 ,
2016-06-12 10:19:56 +02:00
data_only = > 1 ,
section_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP EXTENSION plpgsql' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
2016-11-18 20:21:33 +01:00
catch_all = > 'DROP ... commands' ,
2017-01-31 18:42:16 +01:00
regexp = > qr/^DROP EXTENSION plpgsql;/ m ,
like = > { clean = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP FUNCTION dump_test.pltestlang_call_handler()' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP FUNCTION dump_test\.pltestlang_call_handler\(\);/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP LANGUAGE pltestlang' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP PROCEDURAL LANGUAGE pltestlang;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP SCHEMA dump_test' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP SCHEMA dump_test;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP SCHEMA dump_test_second_schema' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP SCHEMA dump_test_second_schema;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP TABLE test_table' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP TABLE dump_test\.test_table;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP TABLE fk_reference_test_table' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP TABLE dump_test\.fk_reference_test_table;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP TABLE test_second_table' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP TABLE dump_test\.test_second_table;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP TABLE test_third_table' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP TABLE dump_test_second_schema\.test_third_table;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP EXTENSION IF EXISTS plpgsql' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP EXTENSION IF EXISTS plpgsql;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP FUNCTION IF EXISTS dump_test.pltestlang_call_handler()' = > {
regexp = > qr / ^
\ QDROP FUNCTION IF EXISTS dump_test . pltestlang_call_handler ( ) ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP LANGUAGE IF EXISTS pltestlang' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP PROCEDURAL LANGUAGE IF EXISTS pltestlang;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP SCHEMA IF EXISTS dump_test' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP SCHEMA IF EXISTS dump_test;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP SCHEMA IF EXISTS dump_test_second_schema' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP SCHEMA IF EXISTS dump_test_second_schema;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP TABLE IF EXISTS test_table' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP TABLE IF EXISTS dump_test\.test_table;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP TABLE IF EXISTS test_second_table' = > {
2016-05-07 22:36:50 +02:00
regexp = > qr/^DROP TABLE IF EXISTS dump_test\.test_second_table;/ m ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'DROP TABLE IF EXISTS test_third_table' = > {
regexp = > qr / ^
\ QDROP TABLE IF EXISTS dump_test_second_schema . test_third_table ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
2016-06-12 10:19:56 +02:00
like = > { clean_if_exists = > 1 , } ,
2016-11-18 20:21:33 +01:00
unlike = > {
clean = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
2016-07-18 00:42:31 +02:00
'DROP ROLE regress_dump_test_role' = > {
2016-05-25 05:31:55 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QDROP ROLE regress_dump_test_role ; \ E
2016-05-25 05:31:55 +02:00
/ xm ,
2016-06-12 10:19:56 +02:00
like = > { pg_dumpall_globals_clean = > 1 , } ,
2016-05-25 05:31:55 +02:00
unlike = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-05-25 05:31:55 +02:00
'DROP ROLE pg_' = > {
regexp = > qr / ^
\ QDROP ROLE pg_ \ E . * ;
/ xm ,
2017-01-31 18:42:16 +01:00
like = > { } ,
2016-05-25 05:31:55 +02:00
unlike = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
pg_dumpall_globals_clean = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-06-12 10:19:56 +02:00
'DROP ... commands' = > { # catch-all for DROP
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^DROP / m ,
like = > { } , # use more-specific options above
unlike = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
column_inserts = > 1 ,
createdb = > 1 ,
data_only = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
schema_only = > 1 ,
section_data = > 1 ,
section_pre_data = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'GRANT USAGE ON SCHEMA dump_test_second_schema' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 10 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' GRANT USAGE ON SCHEMA dump_test_second_schema
2016-07-18 00:42:31 +02:00
TO regress_dump_test_role ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QGRANT USAGE ON SCHEMA dump_test_second_schema TO regress_dump_test_role ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-07-17 15:04:46 +02:00
'GRANT CREATE ON DATABASE dump_test' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
2016-07-17 15:04:46 +02:00
create_order = > 48 ,
2016-08-15 19:42:51 +02:00
create_sql = >
'GRANT CREATE ON DATABASE dump_test TO regress_dump_test_role;' ,
2016-07-17 15:04:46 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QGRANT CREATE ON DATABASE dump_test TO regress_dump_test_role ; \ E
2016-07-17 15:04:46 +02:00
/ xm ,
2016-08-15 19:42:51 +02:00
like = > { pg_dumpall_dbprivs = > 1 , } ,
2016-07-17 15:04:46 +02:00
unlike = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-07-17 15:04:46 +02:00
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-07-17 15:04:46 +02:00
schema_only = > 1 ,
2016-08-15 19:42:51 +02:00
section_pre_data = > 1 ,
2016-07-17 15:04:46 +02:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'GRANT SELECT ON TABLE test_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 5 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' GRANT SELECT ON TABLE dump_test . test_table
2016-07-18 00:42:31 +02:00
TO regress_dump_test_role ; ' ,
2016-08-15 19:42:51 +02:00
regexp = >
qr/^GRANT SELECT ON TABLE test_table TO regress_dump_test_role;/ m ,
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
unlike = > {
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals = > 1 ,
role = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'GRANT SELECT ON TABLE test_third_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 19 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' GRANT SELECT ON
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
TABLE dump_test_second_schema . test_third_table
2016-07-18 00:42:31 +02:00
TO regress_dump_test_role ; ' ,
2016-08-15 19:42:51 +02:00
regexp = >
qr/^GRANT SELECT ON TABLE test_third_table TO regress_dump_test_role;/ m ,
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'GRANT ALL ON SEQUENCE test_third_table_col1_seq' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 28 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' GRANT ALL ON SEQUENCE
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
dump_test_second_schema . test_third_table_col1_seq
2016-07-18 00:42:31 +02:00
TO regress_dump_test_role ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QGRANT ALL ON SEQUENCE test_third_table_col1_seq TO regress_dump_test_role ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-11-18 20:21:33 +01:00
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'GRANT INSERT(col1) ON TABLE test_second_table' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 8 ,
2016-06-12 10:19:56 +02:00
create_sql = >
' GRANT INSERT ( col1 ) ON TABLE dump_test . test_second_table
2016-07-18 00:42:31 +02:00
TO regress_dump_test_role ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QGRANT INSERT ( col1 ) ON TABLE test_second_table TO regress_dump_test_role ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 ,
test_schema_plus_blobs = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals = > 1 ,
role = > 1 , } , } ,
2016-07-18 00:42:31 +02:00
'GRANT EXECUTE ON FUNCTION pg_sleep() TO regress_dump_test_role' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 16 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' GRANT EXECUTE ON FUNCTION pg_sleep ( float8 )
2016-07-18 00:42:31 +02:00
TO regress_dump_test_role ; ' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
regexp = > qr / ^
2016-07-18 00:42:31 +02:00
\ QGRANT ALL ON FUNCTION pg_sleep ( double precision ) TO regress_dump_test_role ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals = > 1 ,
role = > 1 ,
2016-06-12 10:19:56 +02:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'GRANT SELECT (proname ...) ON TABLE pg_proc TO public' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'GRANT commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 46 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' GRANT SELECT (
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
tableoid ,
oid ,
proname ,
pronamespace ,
proowner ,
prolang ,
procost ,
prorows ,
provariadic ,
protransform ,
proisagg ,
proiswindow ,
prosecdef ,
proleakproof ,
proisstrict ,
proretset ,
provolatile ,
proparallel ,
pronargs ,
pronargdefaults ,
prorettype ,
proargtypes ,
proallargtypes ,
proargmodes ,
proargnames ,
proargdefaults ,
protrftypes ,
prosrc ,
probin ,
proconfig ,
proacl
) ON TABLE pg_proc TO public ; ' ,
regexp = > qr /
\ QGRANT SELECT ( tableoid ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( oid ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proname ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( pronamespace ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proowner ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( prolang ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( procost ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( prorows ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( provariadic ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( protransform ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proisagg ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proiswindow ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( prosecdef ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proleakproof ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proisstrict ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proretset ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( provolatile ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proparallel ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( pronargs ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( pronargdefaults ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( prorettype ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proargtypes ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proallargtypes ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proargmodes ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proargnames ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proargdefaults ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( protrftypes ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( prosrc ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( probin ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
\ QGRANT SELECT ( proconfig ) ON TABLE pg_proc TO PUBLIC ; \ E \ n . *
2016-05-07 22:36:50 +02:00
\ QGRANT SELECT ( proacl ) ON TABLE pg_proc TO PUBLIC ; \ E / xms ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals = > 1 ,
role = > 1 ,
2016-06-12 10:19:56 +02:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-06-12 10:19:56 +02:00
'GRANT commands' = > { # catch-all for GRANT commands
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^GRANT / m ,
like = > { } , # use more-specific options above
unlike = > {
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
no_privs = > 1 ,
pg_dumpall_globals_clean = > 1 ,
section_data = > 1 ,
section_post_data = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'REFRESH MATERIALIZED VIEW matview' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr/^REFRESH MATERIALIZED VIEW matview;/ m ,
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
test_schema_plus_blobs = > 1 ,
section_post_data = > 1 , } ,
unlike = > {
binary_upgrade = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
2016-06-12 10:19:56 +02:00
exclude_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_pre_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'REFRESH MATERIALIZED VIEW matview_second' = > {
2016-11-18 20:21:33 +01:00
all_runs = > 1 ,
2017-01-31 18:42:16 +01:00
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QREFRESH MATERIALIZED VIEW matview ; \ E
\ n . *
\ QREFRESH MATERIALIZED VIEW matview_second ; \ E
2016-05-07 22:36:50 +02:00
/ xms ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_test_table = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_privs = > 1 ,
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
test_schema_plus_blobs = > 1 ,
section_post_data = > 1 , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
unlike = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
2016-11-18 20:21:33 +01:00
column_inserts = > 1 ,
data_only = > 1 ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
exclude_dump_test_schema = > 1 ,
2016-06-12 10:19:56 +02:00
only_dump_test_table = > 1 ,
pg_dumpall_globals = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-06-12 10:19:56 +02:00
section_pre_data = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
2016-07-17 15:04:46 +02:00
'REVOKE CONNECT ON DATABASE dump_test FROM public' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'REVOKE commands' ,
2016-07-17 15:04:46 +02:00
create_order = > 49 ,
create_sql = > 'REVOKE CONNECT ON DATABASE dump_test FROM public;' ,
2016-08-15 19:42:51 +02:00
regexp = > qr / ^
2016-07-17 15:04:46 +02:00
\ QREVOKE CONNECT , TEMPORARY ON DATABASE dump_test FROM PUBLIC ; \ E \ n
2016-10-13 16:46:22 +02:00
\ QGRANT TEMPORARY ON DATABASE dump_test TO PUBLIC ; \ E \ n
\ QGRANT CREATE ON DATABASE dump_test TO regress_dump_test_role ; \ E
2016-07-17 15:04:46 +02:00
/ xm ,
2016-08-15 19:42:51 +02:00
like = > { pg_dumpall_dbprivs = > 1 , } ,
2016-07-17 15:04:46 +02:00
unlike = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-07-17 15:04:46 +02:00
no_owner = > 1 ,
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
2016-11-18 20:21:33 +01:00
pg_dumpall_globals = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
2016-07-17 15:04:46 +02:00
schema_only = > 1 ,
2016-11-18 20:21:33 +01:00
section_data = > 1 ,
2016-07-17 15:04:46 +02:00
section_pre_data = > 1 ,
2016-11-18 20:21:33 +01:00
section_post_data = > 1 ,
2016-07-17 15:04:46 +02:00
test_schema_plus_blobs = > 1 , } , } ,
2016-11-18 20:21:33 +01:00
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'REVOKE EXECUTE ON FUNCTION pg_sleep() FROM public' = > {
2017-01-31 18:42:16 +01:00
all_runs = > 1 ,
catch_all = > 'REVOKE commands' ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
create_order = > 15 ,
2016-06-12 10:19:56 +02:00
create_sql = > ' REVOKE EXECUTE ON FUNCTION pg_sleep ( float8 )
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
FROM public ; ' ,
regexp = > qr / ^
\ QREVOKE ALL ON FUNCTION pg_sleep ( double precision ) FROM PUBLIC ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_data = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'REVOKE SELECT ON TABLE pg_proc FROM public' = > {
create_order = > 45 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'REVOKE SELECT ON TABLE pg_proc FROM public;' ,
regexp = > qr/^REVOKE SELECT ON TABLE pg_proc FROM PUBLIC;/ m ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_data = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'REVOKE CREATE ON SCHEMA public FROM public' = > {
create_order = > 16 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'REVOKE CREATE ON SCHEMA public FROM public;' ,
regexp = > qr / ^
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
\ QREVOKE ALL ON SCHEMA public FROM PUBLIC ; \ E
\ n \ QGRANT USAGE ON SCHEMA public TO PUBLIC ; \ E
2016-05-07 22:36:50 +02:00
/ xm ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like = > {
2016-06-12 10:19:56 +02:00
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_data = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
'REVOKE USAGE ON LANGUAGE plpgsql FROM public' = > {
create_order = > 16 ,
2016-06-12 10:19:56 +02:00
create_sql = > 'REVOKE USAGE ON LANGUAGE plpgsql FROM public;' ,
regexp = > qr/^REVOKE ALL ON LANGUAGE plpgsql FROM PUBLIC;/ m ,
like = > {
binary_upgrade = > 1 ,
clean = > 1 ,
clean_if_exists = > 1 ,
createdb = > 1 ,
defaults = > 1 ,
exclude_dump_test_schema = > 1 ,
exclude_test_table = > 1 ,
exclude_test_table_data = > 1 ,
2016-11-29 17:09:35 +01:00
no_blobs = > 1 ,
2016-06-12 10:19:56 +02:00
no_owner = > 1 ,
2016-07-17 15:04:46 +02:00
pg_dumpall_dbprivs = > 1 ,
2016-06-12 10:19:56 +02:00
schema_only = > 1 ,
section_pre_data = > 1 , } ,
unlike = > {
2016-11-18 20:21:33 +01:00
only_dump_test_schema = > 1 ,
only_dump_test_table = > 1 ,
pg_dumpall_globals_clean = > 1 ,
role = > 1 ,
section_data = > 1 ,
section_post_data = > 1 ,
test_schema_plus_blobs = > 1 , } , } ,
2016-06-12 10:19:56 +02:00
'REVOKE commands' = > { # catch-all for REVOKE commands
2017-01-31 18:42:16 +01:00
all_runs = > 0 , # catch-all
regexp = > qr/^REVOKE / m ,
like = > { } , # use more-specific options above
unlike = > {
2016-06-12 10:19:56 +02:00
column_inserts = > 1 ,
data_only = > 1 ,
no_privs = > 1 ,
pg_dumpall_globals = > 1 , } , } , ) ;
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
#########################################
# Create a PG instance to test actually dumping from
my $ node = get_new_node ( 'main' ) ;
$ node - > init ;
$ node - > start ;
my $ port = $ node - > port ;
# Start with 2 because of command_exit_is() tests below
my $ num_tests = 2 ;
2016-06-12 10:19:56 +02:00
foreach my $ run ( sort keys % pgdump_runs )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
my $ test_key = $ run ;
# Each run of pg_dump is a test itself
$ num_tests + + ;
# If there is a restore cmd, that's another test
2016-06-12 10:19:56 +02:00
if ( $ pgdump_runs { $ run } - > { restore_cmd } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
$ num_tests + + ;
}
2016-06-12 10:19:56 +02:00
if ( $ pgdump_runs { $ run } - > { test_key } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
$ test_key = $ pgdump_runs { $ run } - > { test_key } ;
}
# Then count all the tests run against each run
2016-06-12 10:19:56 +02:00
foreach my $ test ( sort keys % tests )
{
if ( $ tests { $ test } - > { like } - > { $ test_key } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
$ num_tests + + ;
}
2016-06-12 10:19:56 +02:00
if ( $ tests { $ test } - > { unlike } - > { $ test_key } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
$ num_tests + + ;
}
2016-11-18 20:21:33 +01:00
if ( $ tests { $ test } - > { all_runs } )
{
$ num_tests + + ;
}
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
}
}
plan tests = > $ num_tests ;
#########################################
# Set up schemas, tables, etc, to be dumped.
# Build up the create statements
my $ create_sql = '' ;
foreach my $ test (
sort {
2016-06-12 10:19:56 +02:00
if ( $ tests { $ a } - > { create_order } and $ tests { $ b } - > { create_order } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
$ tests { $ a } - > { create_order } <=> $ tests { $ b } - > { create_order } ;
2016-06-12 10:19:56 +02:00
}
elsif ( $ tests { $ a } - > { create_order } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
- 1 ;
2016-06-12 10:19:56 +02:00
}
elsif ( $ tests { $ b } - > { create_order } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
1 ;
2016-06-12 10:19:56 +02:00
}
else
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
0 ;
}
2016-06-12 10:19:56 +02:00
} keys % tests )
{
if ( $ tests { $ test } - > { create_sql } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
$ create_sql . = $ tests { $ test } - > { create_sql } ;
}
}
# Send the combined set of commands to psql
$ node - > safe_psql ( 'postgres' , $ create_sql ) ;
#########################################
# Test connecting to a non-existent database
2016-06-12 10:19:56 +02:00
command_exit_is (
[ 'pg_dump' , '-p' , "$port" , 'qqq' ] ,
1 ,
'pg_dump: [archiver (db)] connection to database "qqq" failed: FATAL: database "qqq" does not exist'
) ;
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
2016-07-18 00:42:31 +02:00
command_exit_is ( [ 'pg_dump' , '-p' , "$port" , '--role=regress_dump_test_role' ] ,
2016-06-12 10:19:56 +02:00
1 ,
'pg_dump: [archiver (db)] query failed: ERROR: permission denied for' ) ;
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
#########################################
# Run all runs
2016-06-12 10:19:56 +02:00
foreach my $ run ( sort keys % pgdump_runs )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
my $ test_key = $ run ;
2016-06-12 10:19:56 +02:00
$ node - > command_ok ( \ @ { $ pgdump_runs { $ run } - > { dump_cmd } } ,
"$run: pg_dump runs" ) ;
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
2016-06-12 10:19:56 +02:00
if ( $ pgdump_runs { $ run } - > { restore_cmd } )
{
$ node - > command_ok ( \ @ { $ pgdump_runs { $ run } - > { restore_cmd } } ,
"$run: pg_restore runs" ) ;
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
}
2016-06-12 10:19:56 +02:00
if ( $ pgdump_runs { $ run } - > { test_key } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
$ test_key = $ pgdump_runs { $ run } - > { test_key } ;
}
my $ output_file = slurp_file ( "$tempdir/${run}.sql" ) ;
#########################################
# Run all tests where this run is included
# as either a 'like' or 'unlike' test.
2016-06-12 10:19:56 +02:00
foreach my $ test ( sort keys % tests )
{
if ( $ tests { $ test } - > { like } - > { $ test_key } )
{
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
like ( $ output_file , $ tests { $ test } - > { regexp } , "$run: dumps $test" ) ;
}
2016-06-12 10:19:56 +02:00
if ( $ tests { $ test } - > { unlike } - > { $ test_key } )
{
unlike (
$ output_file ,
$ tests { $ test } - > { regexp } ,
"$run: does not dump $test" ) ;
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
}
2017-01-31 18:42:16 +01:00
# Complain if there isn't a like or unlike for this test, unless that is ok
2016-11-18 20:21:33 +01:00
if ( $ tests { $ test } - > { all_runs } )
{
if ( ! defined ( $ tests { $ test } - > { catch_all } ) )
{
2017-01-31 18:42:16 +01:00
ok ( defined ( $ tests { $ test } - > { like } - > { $ test_key } )
|| defined ( $ tests { $ test } - > { unlike } - > { $ test_key } ) ,
"$run defined for `$test'" ) ;
2016-11-18 20:21:33 +01:00
}
else
{
my $ catch_all = $ tests { $ test } - > { catch_all } ;
2017-01-31 18:42:16 +01:00
ok ( defined ( $ tests { $ test } - > { like } - > { $ test_key } )
|| defined ( $ tests { $ catch_all } - > { like } - > { $ test_key } )
|| defined ( $ tests { $ test } - > { unlike } - > { $ test_key } )
|| defined ( $ tests { $ catch_all } - > { unlike } - > { $ test_key } ) ,
2016-11-18 20:21:33 +01:00
"$run defined for `$test' or `$catch_all'" ) ;
}
}
Add TAP tests for pg_dump
This TAP test suite will create a new cluster, populate it based on
the 'create_sql' values in the '%tests' hash, run all of the runs
defined in the '%pgdump_runs' hash, and then for each test in the
'%tests' hash, compare each run's output the the regular expression
defined for the test under the 'like' and 'unlike' functions, as
appropriate.
While this test suite covers a fair bit of ground (67% of pg_dump.c
and quite a bit of the other files in src/bin/pg_dump), there is
still quite a bit which remains to be added to provide better code
coverage. Still, this is quite a bit better than we had, and has
found a few bugs already (note that the CREATE TRANSFORM test is
commented out, as it is currently failing).
Idea for using the TAP system from Tom, though all of the code is mine.
2016-05-06 20:06:50 +02:00
}
}
#########################################
# Stop the database instance, which will be removed at the end of the tests.
$ node - > stop ( 'fast' ) ;