Skip to content

Test PGXNTOOL_VERIFY_RESULTS_MODE validation - #99

Merged
jnasbyupgrade merged 2 commits into
Postgres-Extensions:masterfrom
jnasbyupgrade:pre-2.4.0-verify-results-mode
Oct 7, 2026
Merged

jnasbyupgrade merged 2 commits into
Postgres-Extensions:masterfrom
jnasbyupgrade:pre-2.4.0-verify-results-mode

Conversation

@jnasbyupgrade

Copy link
Copy Markdown
Contributor

This PR adds test coverage for Postgres-Extensions/pgxntool#132, which validates PGXNTOOL_VERIFY_RESULTS_MODE. The variable now accepts pgtap or diffs case-insensitively, and any other value is a parse-time error.

Merge Postgres-Extensions/pgxntool#132 first. These tests check behavior that doesn't exist on pgxntool master yet. If this PR lands first, CI fails for every unpaired pgxntool-test PR until #132 merges. See CLAUDE.md, "Merge Order for Paired PRs".

New test/standard/make-test.bats cases

  • Accepts valid values: with no value set, print-PGXNTOOL_VERIFY_RESULTS_MODE shows pgtap. pgtap, pgTap, PGTAP, diffs, Diffs and DIFFS each print the lowercase value.
  • Rejects invalid values: bogus, pgtapp, pgtap diffs and an empty value each fail with PGXNTOOL_VERIFY_RESULTS_MODE must be one of: pgtap diffs; got "<value>".
  • Selects the right recipe: make -n verify-results with pgTap shows the verify-results-pgtap.sh recipe. With DIFFS it shows the inline regression.diffs check. This guards against the original bug, where a mixed-case value silently selected the diffs recipe.

All three cases run at the print-/make -n layer and don't need a database.

🤖 Generated with Claude Code

Add tests for pgxntool commit 7a7e9fb
(Postgres-Extensions/pgxntool#132), which validates
`PGXNTOOL_VERIFY_RESULTS_MODE`:
- Accepts `pgtap`/`diffs` case-insensitively
- Rejects anything else, including empty, with a parse-time error

New `make-test.bats` cases:
- Default and mixed-case values normalize correctly via `print-`
- Invalid, multi-word and empty values fail with the expected message
- Mixed-case values select the matching `verify-results` recipe (`make -n`)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 38240290-cb6a-450f-aa94-0154a15db199

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

jnasbyupgrade added a commit to Postgres-Extensions/pgxntool that referenced this pull request Oct 7, 2026
`PGXNTOOL_VERIFY_RESULTS_MODE` is now validated: it accepts `pgtap` or
`diffs`, case-insensitively, and any other value is a parse-time `make`
error. Before this, any value other than exactly `pgtap` (for example
the typo `pgTap`) silently selected `diffs` mode and weakened the `make
results` safeguard.

Paired pgxntool-test PR:
Postgres-Extensions/pgxntool-test#99

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
@jnasbyupgrade
jnasbyupgrade merged commit 7a30139 into Postgres-Extensions:master Oct 7, 2026
9 checks passed
@jnasbyupgrade
jnasbyupgrade deleted the pre-2.4.0-verify-results-mode branch October 7, 2026 22:40
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