Skip to content

Fix results ordering, control file whitespace, ENABLE_* overrides#19

Open
jnasbyupgrade wants to merge 2 commits into
Postgres-Extensions:masterfrom
jnasbyupgrade:fix-pr69-issues
Open

Fix results ordering, control file whitespace, ENABLE_* overrides#19
jnasbyupgrade wants to merge 2 commits into
Postgres-Extensions:masterfrom
jnasbyupgrade:fix-pr69-issues

Conversation

@jnasbyupgrade
Copy link
Copy Markdown
Contributor

Related pgxntool PR: Postgres-Extensions/pgxntool#31

Summary

Tests and template updates for pgxntool commit 20c2552:

  • make-results.bats: new test verifying verify-results blocks make results when tests are failing (exercises the fixed results: test verify-results ordering)
  • test-verify-results.bats: remove make results assertion that now requires PostgreSQL (since make results runs make test first after the fix); add clarifying comments
  • New 04-pgtle.bats test: pgtle.sh correctly handles multiple spaces and tab before trailing comment in control files
  • template-multi-extension/ext_beta.control: use multiple spaces before trailing comment to exercise whitespace trimming
  • multi-extension.bats: update comments for multiple-spaces testing
  • test.md agent: fix debug level description (BATS 1–5 scale is separate from lib.sh 10–50 scale)
  • gather-repo-info.sh: add sanity check that flags multi-digit non-multiples-of-10 debug levels

…ce, overrides)

Add tests/updates for pgxntool commit 20c2552:
- Fix `results:` ordering: `verify-results` now runs after `test` (not before)
- Fix `parse_control_file` trailing whitespace stripping (multiple spaces/tabs)
- Add `override` to `PGXNTOOL_ENABLE_*` so command-line values are normalized

- `make-results.bats`: new test verifying `verify-results` blocks `make results`
  when tests are failing; updated comments
- `test-verify-results.bats`: remove `make results` assertion (now requires
  PostgreSQL since `make results` runs `make test` first); add clarifying comments
- New `04-pgtle.bats` test: `pgtle.sh` handles multiple spaces and tab before
  trailing comment in control files
- `template-multi-extension/ext_beta.control`: use multiple spaces before
  trailing comment to exercise whitespace trimming
- `multi-extension.bats`: update comments for multiple-spaces testing
- `test.md` agent: fix debug level description (BATS 1–5 scale vs `lib.sh` 10–50)
- `gather-repo-info.sh`: add sanity check for invalid debug levels

Co-Authored-By: Claude <noreply@anthropic.com>
@jnasbyupgrade jnasbyupgrade changed the title Add tests for pgxntool PR #31 (fix results ordering, whitespace, overrides) Fix results ordering, control file whitespace, ENABLE_* overrides May 15, 2026
Updates for pgxntool commit 6e707bb (clarify debug() level scheme):
- `lib.sh` comment updated to range-based scheme (1-9, 10-19, 20-29...)

`test/lib/helpers.bash`: `debug()` now checks `$TESTDEBUG` instead of `$DEBUG`,
so test infrastructure verbosity and pgxntool script verbosity are independently
controlled. Use `TESTDEBUG=N` for test runs, `DEBUG=N` for pgxntool scripts.

`.claude/skills/commit/SKILL.md`: Added Step 2b — advisory scan of debug level
distribution in changed pgxntool `.sh` files at commit time. Flags scripts with
loops but only single-digit levels, or 5+ calls all at the same level.

`.claude/agents/test.md`, `.claude/settings.json`: Updated all `DEBUG=` references
to `TESTDEBUG=`; corrected stale debug level descriptions to match helpers.bash.

`.claude/skills/test/scripts/run-tests.sh`: Derive `PGPORT` from `PGCLUSTER` at
startup so pg_regress and raw PostgreSQL binaries use the correct cluster port.

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant