Skip to content

test(den-web): assert install-link error intent instead of stale copy - #3107

Merged
benjaminshafii merged 1 commit into
devfrom
fix/install-link-error-copy-drift
Jul 25, 2026
Merged

test(den-web): assert install-link error intent instead of stale copy#3107
benjaminshafii merged 1 commit into
devfrom
fix/install-link-error-copy-drift

Conversation

@benjaminshafii

Copy link
Copy Markdown
Member

Problem

ee/apps/den-web/tests/install-errors.test.ts fails on a clean checkout of dev. The assertion pinned copy that no longer ships:

  • test expected: This install link is expired or no longer available. Ask your organization admin for a fresh link.
  • code returns: This install link has expired or was replaced. Ask your workspace admin for a fresh one from the Members page.

The shipped copy is the better one (it names the Members page), so the test was stale, not the product.

Fix

Assert the actual contract instead of a brittle literal: the message must not leak the raw API error code, and must name the link, the expiry, and who to ask. Wording can now improve without breaking the test.

Verification

pnpm --filter @openwork-ee/den-web exec bun test tests/install-errors.test.ts
  2 pass, 0 fail
pnpm --filter @openwork-ee/den-web test
  73 pass, 0 fail

Found while auditing unrelated work — this one is a pure test fix and unblocks a red suite on dev.

The expired-install-link assertion pinned copy that no longer shipped, so
the suite failed on a clean checkout. Assert the actual contract (no raw
API error code leaks, the message names the link, expiry, and who to ask)
so wording can improve without breaking the test.
@vercel

vercel Bot commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
openwork-app Ready Ready Preview, Comment Jul 25, 2026 1:00pm
openwork-den Ready Ready Preview, Comment Jul 25, 2026 1:00pm
openwork-den-worker-proxy Ready Ready Preview, Comment Jul 25, 2026 1:00pm
openwork-landing Ready Ready Preview, Comment, Open in v0 Jul 25, 2026 1:00pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
openwork-diagnostics Skipped Skipped Jul 25, 2026 1:00pm

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