Skip to content

test(tea-release): create the fixture tag with its message on the command line - #324

Merged
0x73746F66 merged 1 commit into
mainfrom
fix/294-annotated-test-tag
Nov 13, 2026
Merged

0x73746F66 merged 1 commit into
mainfrom
fix/294-annotated-test-tag

Conversation

@0x73746F66

Copy link
Copy Markdown
Member

Closes #294

What

initGitRepo in cmd/tea_release_test.go now runs git tag -a -m "test tag <name>" <name> instead of a bare git tag <name>, and sets tag.gpgsign=false in the throwaway repository next to the existing commit.gpgsign=false.

Why

A bare git tag leaves the lightweight/annotated choice to whatever git config the environment carries. Where that asks for an annotation (signing or forced annotation), git opens an editor and the nine tagged tests fail with Terminal is dumb, but EDITOR unset. Supplying the message on the command line matches how the helper already makes every commit.

gitCommitDate resolves <tag>^{commit} and git describe --tags reads annotated tags, so the tests check the same behaviour.

Verified

go test -run 'TestGitDescribe|TestResolveTeaRelease|TestGitCommitDate' ./cmd/ passes, also with TERM=dumb and no EDITOR.

@github-actions

Copy link
Copy Markdown
Contributor

Vulnetix config plan

Manager gitops:vulnetix/cli, prune off, plan hash a8bd984f1753c68b180298051dd9e2524ab644d2ebe9e4c7c811ff4126753b5f

Object Action Changes
~ QualityGate/default update (adopt) severity: null -> "high"

0 to create, 1 to update, 0 to delete, 0 unchanged

@0x73746F66 0x73746F66 left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reuse review: test-only, one-line fixture fix in cmd/tea_release_test.go (annotated tag message passed on the command line). Uses the existing initGitRepo fixture rather than a new one. No changes needed.

@0x73746F66 0x73746F66 left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reuse review: no reinvented Vulnetix patterns found. The change stays inside the package it covers, uses stdlib/testify helpers already used by the repo's tests, and adds no new client, auth, config-schema or shared-package duplicate (checked internal/testutils and sibling repos). Rebased onto current main locally: go vet and go test pass for every touched package. The earlier red checks (CodeQL Analyze, Install a release with verified provenance, Lockfile) were GitHub API rate-limit failures, not code failures; this will be re-run on a rebased head before merge.

…mand line

initGitRepo ran a bare `git tag <name>`, leaving the lightweight or
annotated choice to the environment's git config. Where that config asks
for an annotation, git opens an editor and the nine tagged tea-release
tests fail with "Terminal is dumb, but EDITOR unset". The helper now
makes an annotated tag with -m (and turns tag signing off, as it already
does for commits); gitCommitDate resolves annotated tags to their commit.

Closes #294
@0x73746F66
0x73746F66 force-pushed the fix/294-annotated-test-tag branch from ae7c3e4 to 1c2d4b8 Compare November 13, 2026 10:35
@github-actions

Copy link
Copy Markdown
Contributor

Vulnetix config plan

Manager gitops:vulnetix/cli, prune off, plan hash a8bd984f1753c68b180298051dd9e2524ab644d2ebe9e4c7c811ff4126753b5f

Object Action Changes
~ QualityGate/default update (adopt) severity: null -> "high"

0 to create, 1 to update, 0 to delete, 0 unchanged

@0x73746F66
0x73746F66 merged commit be90a09 into main Nov 13, 2026
29 of 32 checks passed
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.

Fix initGitRepo to pass -m to git tag so the 9 failing cmd tea-release tests pass under the harness git env

1 participant