Set sequence_range to 1 while initialising nodes for "make check" so that
authorPavan Deolasee <[email protected]>
Fri, 22 Jan 2016 03:36:47 +0000 (09:06 +0530)
committerPavan Deolasee <[email protected]>
Fri, 22 Jan 2016 03:36:47 +0000 (09:06 +0530)
deterministic output is obtained.

This avoids explicit setting of the GUC in every test case that uses serials or
sequences. For those running "make installcheck" they must set it up correctly
in their postgresql.conf files.

We could revert some of the changes done to the test cases (by adding
sequence_range = 1), but this patch does not do that

src/test/regress/pg_regress.c

index 1744f530e4f32bc93573cd808a575d8c830d0724..ed6ff7ba722043d5ad7d82e81fc0250457a1ab9a 100644 (file)
@@ -841,6 +841,11 @@ set_node_config_file(PGXCNodeTypeNum node)
         */
        fputs("max_prepared_transactions = 50\n", pg_conf);
 
+       /*
+        * Set sequence_range to 1 for deterministic results
+        */
+       fputs("sequence_range = 1\n", pg_conf);
+
        /* Set GTM connection information */
        fputs("gtm_host = 'localhost'\n", pg_conf);
        snprintf(buf, sizeof(buf), "gtm_port = %d\n", get_port_number(PGXC_GTM));