Skip to content

Commit ea27936

Browse files
jnasbyupgradeclaude
andcommitted
Note test/install and interactive-debugging tradeoffs for next revisit
Captured per discussion: test/install (cat_tools's pattern) has a real, independent argument for centralizing fresh/update/existing load-mode switching in one place, separate from the schema-targeting question. And the actual debuggability cost of this file's shared/loop-driven design is that interactively \i-ing a traditional, self-contained test file into psql is much more direct than poking at this file's generated names and shared ncs() lookup - not really about automated TAP output specificity, which mostly localizes failures fine already. Not urgent, not changing now, but worth revisiting rather than forgetting next time this file is substantially touched. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
1 parent 3b9eabf commit ea27936

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

test/core/functions.sql

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,25 @@
1+
/*
2+
* TODO, next time this file is substantially touched - reconsider two
3+
* things, not urgent now but worth revisiting rather than forgetting:
4+
*
5+
* 1. test/install (pgxntool's committed-once installer, see
6+
* Postgres-Extensions/cat_tools's test/install/load.sql): cat_tools uses
7+
* it to centralize its fresh/update/existing load-mode switching in ONE
8+
* place, run once, rather than count_nulls's current test/deps.sql
9+
* (loaded per test file, reinstalling every time). That's a real,
10+
* independent argument for test/install regardless of the schema
11+
* question - count_nulls just hasn't needed to revisit it.
12+
*
13+
* 2. The debuggability cost of this file's loop-driven, ncs()-indirected
14+
* design isn't really about automated TAP output (which mostly localizes
15+
* failures fine) - it's that a developer can trivially `psql`, `\i` a
16+
* traditional, self-contained test file, and interactively poke at the
17+
* resulting state; doing the same with this file's generated names and
18+
* shared ncs() lookup is much less direct. That's the actual reason
19+
* count_nulls originally had separate, deliberately-independent smoke
20+
* test files (sanity.sql still is one) alongside this shared helper.
21+
*/
22+
123
CREATE SCHEMA _null_count_test;
224

325
-- See bottom as well!

0 commit comments

Comments
 (0)