Move isolation test index-killtuples to src/test/modules/index/ master github/master
authorMichael Paquier <michael@paquier.xyz>
Mon, 24 Nov 2025 10:33:51 +0000 (19:33 +0900)
committerMichael Paquier <michael@paquier.xyz>
Mon, 24 Nov 2025 10:33:51 +0000 (19:33 +0900)
index-killtuples test depends on the contrib modules btree_gin and
btree_gist, which would not be installed in a temporary installation
with an execution of the main isolation test suite like this one:
make -C src/test/isolation/ check

src/test/isolation/ should not depend on contrib/, and EXTRA_INSTALL has
no effect in this case as this test suite uses its own Makefile rules.

This commit moves index-killtuples into its new module, called "index",
whose name looks like the best fit there can be as it depends on more
than one index AM.  btree_gin and btree_gist are now pulled in the
temporary installation with EXTRA_INSTALL.  The test is renamed to
"killtuples", for simplicity.

Author: Nazir Bilal Yavuz <byavuz81@gmail.com>
Suggested-by: Andres Freund <andres@anarazel.de>
Suggested-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/aKJsWedftW7UX1WM@paquier.xyz

src/test/isolation/isolation_schedule
src/test/modules/Makefile
src/test/modules/index/.gitignore [new file with mode: 0644]
src/test/modules/index/Makefile [new file with mode: 0644]
src/test/modules/index/expected/killtuples.out [moved from src/test/isolation/expected/index-killtuples.out with 100% similarity]
src/test/modules/index/meson.build [new file with mode: 0644]
src/test/modules/index/specs/killtuples.spec [moved from src/test/isolation/specs/index-killtuples.spec with 100% similarity]
src/test/modules/meson.build

index 5afae33d37036aca1a0f4766570dab20cf3c07ab..112f05a3677d2283fdc52a63d88f735b33be3499 100644 (file)
@@ -16,7 +16,6 @@ test: ri-trigger
 test: partial-index
 test: two-ids
 test: multiple-row-versions
 test: partial-index
 test: two-ids
 test: multiple-row-versions
-test: index-killtuples
 test: index-only-scan
 test: index-only-bitmapscan
 test: predicate-lock-hot-tuple
 test: index-only-scan
 test: index-only-bitmapscan
 test: predicate-lock-hot-tuple
index 902a7954101095c78bdb1b4e8af79012dc198d22..d079b91b1a28b949c9b0744ff8ad55609d614658 100644 (file)
@@ -10,6 +10,7 @@ SUBDIRS = \
          delay_execution \
          dummy_index_am \
          dummy_seclabel \
          delay_execution \
          dummy_index_am \
          dummy_seclabel \
+         index \
          libpq_pipeline \
          oauth_validator \
          plsample \
          libpq_pipeline \
          oauth_validator \
          plsample \
diff --git a/src/test/modules/index/.gitignore b/src/test/modules/index/.gitignore
new file mode 100644 (file)
index 0000000..b4903eb
--- /dev/null
@@ -0,0 +1,6 @@
+# Generated subdirectories
+/log/
+/results/
+/output_iso/
+/tmp_check/
+/tmp_check_iso/
diff --git a/src/test/modules/index/Makefile b/src/test/modules/index/Makefile
new file mode 100644 (file)
index 0000000..2904704
--- /dev/null
@@ -0,0 +1,16 @@
+# src/test/modules/index/Makefile
+
+EXTRA_INSTALL = contrib/btree_gin contrib/btree_gist
+
+ISOLATION = killtuples
+
+ifdef USE_PGXS
+PG_CONFIG = pg_config
+PGXS := $(shell $(PG_CONFIG) --pgxs)
+include $(PGXS)
+else
+subdir = src/test/modules/index
+top_builddir = ../../../..
+include $(top_builddir)/src/Makefile.global
+include $(top_srcdir)/contrib/contrib-global.mk
+endif
diff --git a/src/test/modules/index/meson.build b/src/test/modules/index/meson.build
new file mode 100644 (file)
index 0000000..1b3c42d
--- /dev/null
@@ -0,0 +1,12 @@
+# Copyright (c) 2025, PostgreSQL Global Development Group
+
+tests += {
+  'name': 'index',
+  'sd': meson.current_source_dir(),
+  'bd': meson.current_build_dir(),
+  'isolation': {
+    'specs': [
+      'killtuples',
+    ],
+  },
+}
index 14fc761c4cfa931d15d8b96bcaf2c3fef5b2c6b4..f5114469b92e6ea2267b47b585ab04fd1a531742 100644 (file)
@@ -6,6 +6,7 @@ subdir('delay_execution')
 subdir('dummy_index_am')
 subdir('dummy_seclabel')
 subdir('gin')
 subdir('dummy_index_am')
 subdir('dummy_seclabel')
 subdir('gin')
+subdir('index')
 subdir('injection_points')
 subdir('ldap_password_func')
 subdir('libpq_pipeline')
 subdir('injection_points')
 subdir('ldap_password_func')
 subdir('libpq_pipeline')