In 9.6 and up, gin_test_tbl has autovacuum_enabled = off thanks to
commit
f8a1c1d5a. 9.5 lacked that, which allowed autovacuum to
bollix the results of the test case added by commit
8150f7813.
We could fool with disabling seqscan around that test, but making
this branch look more like the later ones seems a better answer.
Per buildfarm member protosciurus. (I'm not very sure why
protosciurus is the only animal to report this so far; but it'd
clearly be a timing-related failure, so it's not astonishing that
only some machines would show it.)
-- There are other tests to test different GIN opclasses. This is for testing
-- GIN itself.
-- Create and populate a test table with a GIN index.
-create table gin_test_tbl(i int4[]);
+create table gin_test_tbl(i int4[]) with (autovacuum_enabled = off);
create index gin_test_idx on gin_test_tbl using gin (i) with (fastupdate = on);
insert into gin_test_tbl select array[1, 2, g] from generate_series(1, 20000) g;
insert into gin_test_tbl select array[1, 3, g] from generate_series(1, 1000) g;
-- GIN itself.
-- Create and populate a test table with a GIN index.
-create table gin_test_tbl(i int4[]);
+create table gin_test_tbl(i int4[]) with (autovacuum_enabled = off);
create index gin_test_idx on gin_test_tbl using gin (i) with (fastupdate = on);
insert into gin_test_tbl select array[1, 2, g] from generate_series(1, 20000) g;
insert into gin_test_tbl select array[1, 3, g] from generate_series(1, 1000) g;