Skip to content

fix(updater): Select first matching main branch - #165

Merged
vaind merged 3 commits into
mainfrom
jpnurmi/test/sentry-cli-branch
May 11, 2026
Merged

fix(updater): Select first matching main branch#165
vaind merged 3 commits into
mainfrom
jpnurmi/test/sentry-cli-branch

Conversation

@jpnurmi

@jpnurmijpnurmi commented May 6, 2026

Copy link
Copy Markdown
Collaborator

sentry-cli currently has main and master pointing at the same HEAD, so the updater started emitting both names in mainBranch=main master output.

[-] update-dependency.output.writes output 1.97s (1.96s|9ms)
Expected 'mainBranch=master' to be found in collection @('originalTag=0', 'latestTag=0.28.0', 'latestTagNice=v0.28.0', 'url=https://github.com/getsentry/sentry-cli', 'mainBranch=main master'), but it was not found.
at $output | Should -Contain 'mainBranch=master', /Users/jpnurmi/Projects/sentry/github-workflows/updater/tests/update-dependency.Tests.ps1:223
at _testOutput, /Users/jpnurmi/Projects/sentry/github-workflows/updater/tests/update-dependency.Tests.ps1:223
at <ScriptBlock>, /Users/jpnurmi/Projects/sentry/github-workflows/updater/tests/update-dependency.Tests.ps1:232

sentry-cli currently has main and master pointing at the same HEAD, so
the updater emits both names in mainBranch output. Match that fixture
output instead of requiring master only.
@jpnurmi
jpnurmi requested a review from vaindMay 6, 2026 17:02
Comment threadupdater/tests/update-dependency.Tests.ps1 Outdated
@jpnurmijpnurmi changed the title test(updater): Update sentry-cli branch assertionfix(updater): Select first matching main branchMay 7, 2026
@github-actions

github-actionsBot commented May 7, 2026

Copy link
Copy Markdown
Contributor
Warnings
⚠️Could not load custom Dangerfile: .github/test-dangerfile-curl.js Error: ENOENT: no such file or directory, lstat '/github/workspace/.github/test-dangerfile-curl.js'

Generated by 🚫 dangerJS against ea0a1fb

@vaind
vaind merged commit 80476a9 into mainMay 11, 2026
25 checks passed
@jpnurmi
jpnurmi deleted the jpnurmi/test/sentry-cli-branch branch May 11, 2026 08:56
vaind added a commit that referenced this pull request May 11, 2026
…#167)
The `writes output` / `writes to env:GITHUB_OUTPUT` tests assert against
the live state of getsentry/sentry-cli via `git ls-remote`. Whether the
script reports `main` or `master` depends on which of the two currently
points at the upstream HEAD, which flips over time. PR #165 baked
`main` into the assertion while both happened to point at HEAD; sentry-cli
has since diverged and post-merge CI on main now reports `master`,
failing the test.
Accept either branch name so the test isn't coupled to transient
upstream branch state.
Sign up for freeto 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.

2 participants

@jpnurmi@vaind