From 7eb4be8c67ec9634df621392631c7a75da191ad6 Mon Sep 17 00:00:00 2001 From: Andrew Pogrebnoy Date: Wed, 4 Jun 2025 16:12:57 +0300 Subject: [PATCH] Remove numbering from TAP test names Numbered TAP tests were done so following the core. However, there is no reason for this, and it creates complications when, for example, we need to remove some tests. Besides, regression tests are in alphabetical order. --- contrib/pg_tde/meson.build | 26 +++++++-------- contrib/pg_tde/t/{001_basic.pl => basic.pl} | 0 ...key_provider.pl => change_key_provider.pl} | 0 ...10_crash_recovery.pl => crash_recovery.pl} | 0 .../pg_tde/t/expected/003_remote_config.out | 32 ------------------- contrib/pg_tde/t/expected/004_file_config.out | 32 ------------------- .../t/expected/006_remote_vault_config.out | 32 ------------------- .../t/expected/{001_basic.out => basic.out} | 0 ...y_provider.out => change_key_provider.out} | 0 ..._crash_recovery.out => crash_recovery.out} | 0 ...blespace.out => key_rotate_tablespace.out} | 0 ...extensions.out => multiple_extensions.out} | 0 .../{009_replication.out => replication.out} | 0 .../{002_rotate_key.out => rotate_key.out} | 0 .../{004_tde_heap.out => tde_heap.out} | 0 ...nlogged_tables.out => unlogged_tables.out} | 0 .../{006_wal_encrypt.out => wal_encrypt.out} | 0 ...tablespace.pl => key_rotate_tablespace.pl} | 0 ...e_extensions.pl => multiple_extensions.pl} | 0 ...vider.pl => pg_tde_change_key_provider.pl} | 0 ...g_waldump_basic.pl => pg_waldump_basic.pl} | 0 ...ump_fullpage.pl => pg_waldump_fullpage.pl} | 0 .../t/{009_replication.pl => replication.pl} | 0 .../t/{002_rotate_key.pl => rotate_key.pl} | 0 .../pg_tde/t/{004_tde_heap.pl => tde_heap.pl} | 0 ..._unlogged_tables.pl => unlogged_tables.pl} | 0 .../t/{006_wal_encrypt.pl => wal_encrypt.pl} | 0 27 files changed, 13 insertions(+), 109 deletions(-) rename contrib/pg_tde/t/{001_basic.pl => basic.pl} (100%) rename contrib/pg_tde/t/{007_change_key_provider.pl => change_key_provider.pl} (100%) rename contrib/pg_tde/t/{010_crash_recovery.pl => crash_recovery.pl} (100%) delete mode 100644 contrib/pg_tde/t/expected/003_remote_config.out delete mode 100644 contrib/pg_tde/t/expected/004_file_config.out delete mode 100644 contrib/pg_tde/t/expected/006_remote_vault_config.out rename contrib/pg_tde/t/expected/{001_basic.out => basic.out} (100%) rename contrib/pg_tde/t/expected/{007_change_key_provider.out => change_key_provider.out} (100%) rename contrib/pg_tde/t/expected/{010_crash_recovery.out => crash_recovery.out} (100%) rename contrib/pg_tde/t/expected/{005_key_rotate_tablespace.out => key_rotate_tablespace.out} (100%) rename contrib/pg_tde/t/expected/{003_multiple_extensions.out => multiple_extensions.out} (100%) rename contrib/pg_tde/t/expected/{009_replication.out => replication.out} (100%) rename contrib/pg_tde/t/expected/{002_rotate_key.out => rotate_key.out} (100%) rename contrib/pg_tde/t/expected/{004_tde_heap.out => tde_heap.out} (100%) rename contrib/pg_tde/t/expected/{008_unlogged_tables.out => unlogged_tables.out} (100%) rename contrib/pg_tde/t/expected/{006_wal_encrypt.out => wal_encrypt.out} (100%) rename contrib/pg_tde/t/{005_key_rotate_tablespace.pl => key_rotate_tablespace.pl} (100%) rename contrib/pg_tde/t/{003_multiple_extensions.pl => multiple_extensions.pl} (100%) rename contrib/pg_tde/t/{013_pg_tde_change_key_provider.pl => pg_tde_change_key_provider.pl} (100%) rename contrib/pg_tde/t/{011_pg_waldump_basic.pl => pg_waldump_basic.pl} (100%) rename contrib/pg_tde/t/{012_pg_waldump_fullpage.pl => pg_waldump_fullpage.pl} (100%) rename contrib/pg_tde/t/{009_replication.pl => replication.pl} (100%) rename contrib/pg_tde/t/{002_rotate_key.pl => rotate_key.pl} (100%) rename contrib/pg_tde/t/{004_tde_heap.pl => tde_heap.pl} (100%) rename contrib/pg_tde/t/{008_unlogged_tables.pl => unlogged_tables.pl} (100%) rename contrib/pg_tde/t/{006_wal_encrypt.pl => wal_encrypt.pl} (100%) diff --git a/contrib/pg_tde/meson.build b/contrib/pg_tde/meson.build index 7cfa87c353036..7abf96de07030 100644 --- a/contrib/pg_tde/meson.build +++ b/contrib/pg_tde/meson.build @@ -103,19 +103,19 @@ sql_tests = [ ] tap_tests = [ - 't/001_basic.pl', - 't/002_rotate_key.pl', - 't/003_multiple_extensions.pl', - 't/004_tde_heap.pl', - 't/005_key_rotate_tablespace.pl', - 't/006_wal_encrypt.pl', - 't/007_change_key_provider.pl', - 't/008_unlogged_tables.pl', - 't/009_replication.pl', - 't/010_crash_recovery.pl', - 't/011_pg_waldump_basic.pl', - 't/012_pg_waldump_fullpage.pl', - 't/013_pg_tde_change_key_provider.pl', + 't/basic.pl', + 't/change_key_provider.pl', + 't/crash_recovery.pl', + 't/key_rotate_tablespace.pl', + 't/multiple_extensions.pl', + 't/pg_tde_change_key_provider.pl', + 't/pg_waldump_basic.pl', + 't/pg_waldump_fullpage.pl', + 't/replication.pl', + 't/rotate_key.pl', + 't/tde_heap.pl', + 't/unlogged_tables.pl', + 't/wal_encrypt.pl', ] tests += { diff --git a/contrib/pg_tde/t/001_basic.pl b/contrib/pg_tde/t/basic.pl similarity index 100% rename from contrib/pg_tde/t/001_basic.pl rename to contrib/pg_tde/t/basic.pl diff --git a/contrib/pg_tde/t/007_change_key_provider.pl b/contrib/pg_tde/t/change_key_provider.pl similarity index 100% rename from contrib/pg_tde/t/007_change_key_provider.pl rename to contrib/pg_tde/t/change_key_provider.pl diff --git a/contrib/pg_tde/t/010_crash_recovery.pl b/contrib/pg_tde/t/crash_recovery.pl similarity index 100% rename from contrib/pg_tde/t/010_crash_recovery.pl rename to contrib/pg_tde/t/crash_recovery.pl diff --git a/contrib/pg_tde/t/expected/003_remote_config.out b/contrib/pg_tde/t/expected/003_remote_config.out deleted file mode 100644 index 9205431bb2ade..0000000000000 --- a/contrib/pg_tde/t/expected/003_remote_config.out +++ /dev/null @@ -1,32 +0,0 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; -SELECT pg_tde_add_database_key_provider_file('file-provider', json_object('type' VALUE 'remote', 'url' VALUE 'http://localhost:8888/hello')); - pg_tde_add_database_key_provider_file ---------------------------------------- - -(1 row) - -SELECT pg_tde_set_key_using_database_key_provider('test-db-key', 'file-provider'); - pg_tde_set_key_using_database_key_provider --------------------------------------------- - -(1 row) - -CREATE TABLE test_enc2 (id SERIAL, k INTEGER, PRIMARY KEY (id)) USING tde_heap; -INSERT INTO test_enc2 (k) VALUES (5), (6); -SELECT * FROM test_enc2 ORDER BY id; - id | k -----+--- - 1 | 5 - 2 | 6 -(2 rows) - --- server restart -SELECT * FROM test_enc2 ORDER BY id; - id | k -----+--- - 1 | 5 - 2 | 6 -(2 rows) - -DROP TABLE test_enc2; -DROP EXTENSION pg_tde; diff --git a/contrib/pg_tde/t/expected/004_file_config.out b/contrib/pg_tde/t/expected/004_file_config.out deleted file mode 100644 index 8031b7df0570d..0000000000000 --- a/contrib/pg_tde/t/expected/004_file_config.out +++ /dev/null @@ -1,32 +0,0 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; -SELECT pg_tde_add_database_key_provider_file('file-provider', json_object('type' VALUE 'file', 'path' VALUE '/tmp/datafile-location')); - pg_tde_add_database_key_provider_file ---------------------------------------- - -(1 row) - -SELECT pg_tde_set_key_using_database_key_provider('test-db-key', 'file-provider'); - pg_tde_set_key_using_database_key_provider --------------------------------------------- - -(1 row) - -CREATE TABLE test_enc1 (id SERIAL, k INTEGER, PRIMARY KEY (id)) USING tde_heap; -INSERT INTO test_enc1 (k) VALUES (5), (6); -SELECT * FROM test_enc1 ORDER BY id; - id | k -----+--- - 1 | 5 - 2 | 6 -(2 rows) - --- server restart -SELECT * FROM test_enc1 ORDER BY id; - id | k -----+--- - 1 | 5 - 2 | 6 -(2 rows) - -DROP TABLE test_enc1; -DROP EXTENSION pg_tde; diff --git a/contrib/pg_tde/t/expected/006_remote_vault_config.out b/contrib/pg_tde/t/expected/006_remote_vault_config.out deleted file mode 100644 index 9a467d9b13876..0000000000000 --- a/contrib/pg_tde/t/expected/006_remote_vault_config.out +++ /dev/null @@ -1,32 +0,0 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; -SELECT pg_tde_add_database_key_provider_vault_v2('vault-provider', json_object('type' VALUE 'remote', 'url' VALUE 'http://localhost:8889/token'), json_object('type' VALUE 'remote', 'url' VALUE 'http://localhost:8889/url'), to_json('secret'::text), NULL); - pg_tde_add_database_key_provider_vault_v2 -------------------------------------------- - -(1 row) - -SELECT pg_tde_set_key_using_database_key_provider('test-db-key', 'vault-provider'); - pg_tde_set_key_using_database_key_provider --------------------------------------------- - -(1 row) - -CREATE TABLE test_enc2 (id SERIAL, k INTEGER, PRIMARY KEY (id)) USING tde_heap; -INSERT INTO test_enc2 (k) VALUES (5), (6); -SELECT * FROM test_enc2 ORDER BY id; - id | k -----+--- - 1 | 5 - 2 | 6 -(2 rows) - --- server restart -SELECT * FROM test_enc2 ORDER BY id; - id | k -----+--- - 1 | 5 - 2 | 6 -(2 rows) - -DROP TABLE test_enc2; -DROP EXTENSION pg_tde; diff --git a/contrib/pg_tde/t/expected/001_basic.out b/contrib/pg_tde/t/expected/basic.out similarity index 100% rename from contrib/pg_tde/t/expected/001_basic.out rename to contrib/pg_tde/t/expected/basic.out diff --git a/contrib/pg_tde/t/expected/007_change_key_provider.out b/contrib/pg_tde/t/expected/change_key_provider.out similarity index 100% rename from contrib/pg_tde/t/expected/007_change_key_provider.out rename to contrib/pg_tde/t/expected/change_key_provider.out diff --git a/contrib/pg_tde/t/expected/010_crash_recovery.out b/contrib/pg_tde/t/expected/crash_recovery.out similarity index 100% rename from contrib/pg_tde/t/expected/010_crash_recovery.out rename to contrib/pg_tde/t/expected/crash_recovery.out diff --git a/contrib/pg_tde/t/expected/005_key_rotate_tablespace.out b/contrib/pg_tde/t/expected/key_rotate_tablespace.out similarity index 100% rename from contrib/pg_tde/t/expected/005_key_rotate_tablespace.out rename to contrib/pg_tde/t/expected/key_rotate_tablespace.out diff --git a/contrib/pg_tde/t/expected/003_multiple_extensions.out b/contrib/pg_tde/t/expected/multiple_extensions.out similarity index 100% rename from contrib/pg_tde/t/expected/003_multiple_extensions.out rename to contrib/pg_tde/t/expected/multiple_extensions.out diff --git a/contrib/pg_tde/t/expected/009_replication.out b/contrib/pg_tde/t/expected/replication.out similarity index 100% rename from contrib/pg_tde/t/expected/009_replication.out rename to contrib/pg_tde/t/expected/replication.out diff --git a/contrib/pg_tde/t/expected/002_rotate_key.out b/contrib/pg_tde/t/expected/rotate_key.out similarity index 100% rename from contrib/pg_tde/t/expected/002_rotate_key.out rename to contrib/pg_tde/t/expected/rotate_key.out diff --git a/contrib/pg_tde/t/expected/004_tde_heap.out b/contrib/pg_tde/t/expected/tde_heap.out similarity index 100% rename from contrib/pg_tde/t/expected/004_tde_heap.out rename to contrib/pg_tde/t/expected/tde_heap.out diff --git a/contrib/pg_tde/t/expected/008_unlogged_tables.out b/contrib/pg_tde/t/expected/unlogged_tables.out similarity index 100% rename from contrib/pg_tde/t/expected/008_unlogged_tables.out rename to contrib/pg_tde/t/expected/unlogged_tables.out diff --git a/contrib/pg_tde/t/expected/006_wal_encrypt.out b/contrib/pg_tde/t/expected/wal_encrypt.out similarity index 100% rename from contrib/pg_tde/t/expected/006_wal_encrypt.out rename to contrib/pg_tde/t/expected/wal_encrypt.out diff --git a/contrib/pg_tde/t/005_key_rotate_tablespace.pl b/contrib/pg_tde/t/key_rotate_tablespace.pl similarity index 100% rename from contrib/pg_tde/t/005_key_rotate_tablespace.pl rename to contrib/pg_tde/t/key_rotate_tablespace.pl diff --git a/contrib/pg_tde/t/003_multiple_extensions.pl b/contrib/pg_tde/t/multiple_extensions.pl similarity index 100% rename from contrib/pg_tde/t/003_multiple_extensions.pl rename to contrib/pg_tde/t/multiple_extensions.pl diff --git a/contrib/pg_tde/t/013_pg_tde_change_key_provider.pl b/contrib/pg_tde/t/pg_tde_change_key_provider.pl similarity index 100% rename from contrib/pg_tde/t/013_pg_tde_change_key_provider.pl rename to contrib/pg_tde/t/pg_tde_change_key_provider.pl diff --git a/contrib/pg_tde/t/011_pg_waldump_basic.pl b/contrib/pg_tde/t/pg_waldump_basic.pl similarity index 100% rename from contrib/pg_tde/t/011_pg_waldump_basic.pl rename to contrib/pg_tde/t/pg_waldump_basic.pl diff --git a/contrib/pg_tde/t/012_pg_waldump_fullpage.pl b/contrib/pg_tde/t/pg_waldump_fullpage.pl similarity index 100% rename from contrib/pg_tde/t/012_pg_waldump_fullpage.pl rename to contrib/pg_tde/t/pg_waldump_fullpage.pl diff --git a/contrib/pg_tde/t/009_replication.pl b/contrib/pg_tde/t/replication.pl similarity index 100% rename from contrib/pg_tde/t/009_replication.pl rename to contrib/pg_tde/t/replication.pl diff --git a/contrib/pg_tde/t/002_rotate_key.pl b/contrib/pg_tde/t/rotate_key.pl similarity index 100% rename from contrib/pg_tde/t/002_rotate_key.pl rename to contrib/pg_tde/t/rotate_key.pl diff --git a/contrib/pg_tde/t/004_tde_heap.pl b/contrib/pg_tde/t/tde_heap.pl similarity index 100% rename from contrib/pg_tde/t/004_tde_heap.pl rename to contrib/pg_tde/t/tde_heap.pl diff --git a/contrib/pg_tde/t/008_unlogged_tables.pl b/contrib/pg_tde/t/unlogged_tables.pl similarity index 100% rename from contrib/pg_tde/t/008_unlogged_tables.pl rename to contrib/pg_tde/t/unlogged_tables.pl diff --git a/contrib/pg_tde/t/006_wal_encrypt.pl b/contrib/pg_tde/t/wal_encrypt.pl similarity index 100% rename from contrib/pg_tde/t/006_wal_encrypt.pl rename to contrib/pg_tde/t/wal_encrypt.pl