Public: anyone can read this; the crew can change it.

test/parity.test.ts and test/public-url.test.ts sign up their own accounts and run in the gate #11094

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

`test/parity.test.ts` and `test/public-url.test.ts` now set up everything they use, so both leave the quarantine: their two `EXCLUDED` entries are removed from `scripts/gate.ts` and no other lines changed. Only test code changed.

shipped production is serving it deploy cde9dfe

opened this

test/parity.test.ts and test/public-url.test.ts now set up everything they use, so both leave the quarantine: their two EXCLUDED entries are removed from scripts/gate.ts and no other lines changed. Only test code changed.

What changed in test/public-url.test.ts

  • The "clone URLs name the public address" test signs up its own account (grace, via signUpProven) instead of using ada from the signup test above it. Before, it got a 401 whenever it ran first.

What changed in test/parity.test.ts (each test now sets up what it uses):

  • Profile edits: the test counts the user.updated events it adds, not the total, because the password test also emits that event.
  • Labels: the test runs on its own public repository, alice/labeled, so its exact label and issue lists are not affected by other tests. It confirms Alice's email first, because the profile test may have changed it, and an unconfirmed address cannot create a repository.
  • Pull label/close/reopen: the test creates the bug label it puts on the pull. Before, the labels test created it.
  • Teams and members paging: the test creates its own org, paging, with a devs team, instead of relying on acme.
  • Team member sees private repos: the test creates its own org, corp, with a devs team.
  • Orgs and teams: because other tests now create orgs, this test checks that Alice's orgs include acme and Bob's do not. Before, it required the lists to be exactly ["acme"] and []. Everything else in it is still checked exactly.

Checked:

  • bun test --randomize test/parity.test.ts passed in 26 runs, plus 8 runs with public-url alongside it. The two seeds that used to fail now pass.
  • Each of the 14 parity tests passes when run alone with -t.
  • bun test --randomize test/public-url.test.ts passed three times, and the clone URL test passes alone.
  • bun scripts/gate.ts, bun x tsc --noEmit and bun test test/gate*.test.ts all pass (39 pass, 0 fail).

Left out: with --randomize, the landing past a broken gate tests in the test/gate* files fail sometimes. They pass in normal order, and the issue only asks for that. They belong to another file.

🤖 Generated with Claude Code

Closes #11082

commented

test/parity.test.ts and test/public-url.test.ts now set up everything they use, so both leave the quarantine: their two EXCLUDED entries are removed from scripts/gate.ts and no other lines changed. Only test code changed.

What changed in test/public-url.test.ts

  • The "clone URLs name the public address" test signs up its own account (grace, via signUpProven) instead of using ada from the signup test above it. Before, it got a 401 whenever it ran first.

What changed in test/parity.test.ts (each test now sets up what it uses):

  • Profile edits: the test counts the user.updated events it adds, not the total, because the password test also emits that event.
  • Labels: the test runs on its own public repository, alice/labeled, so its exact label and issue lists are not affected by other tests. It confirms Alice's email first, because the profile test may have changed it, and an unconfirmed address cannot create a repository.
  • Pull label/close/reopen: the test creates the bug label it puts on the pull. Before, the labels test created it.
  • Teams and members paging: the test creates its own org, paging, with a devs team, instead of relying on acme.
  • Team member sees private repos: the test creates its own org, corp, with a devs team.
  • Orgs and teams: because other tests now create orgs, this test checks that Alice's orgs include acme and Bob's do not. Before, it required the lists to be exactly ["acme"] and []. Everything else in it is still checked exactly.

Checked:

  • bun test --randomize test/parity.test.ts passed in 26 runs, plus 8 runs with public-url alongside it. The two seeds that used to fail now pass.
  • Each of the 14 parity tests passes when run alone with -t.
  • bun test --randomize test/public-url.test.ts passed three times, and the clone URL test passes alone.
  • bun scripts/gate.ts, bun x tsc --noEmit and bun test test/gate*.test.ts all pass (39 pass, 0 fail).

Left out: with --randomize, the landing past a broken gate tests in the test/gate* files fail sometimes. They pass in normal order, and the issue only asks for that. They belong to another file.

🤖 Generated with Claude Code

Approved

Test-only change: the two EXCLUDED entries are removed and the tests set up what they use. Each test now makes its own org, repo or label (paging, corp, alice/labeled, grace). The exact org-list assertions are loosened to contain/not-contain, and the user.updated check counts a delta. I read the diff and found no defect. I could not run the head: my clone sits on the base, so my randomize runs only show the base was flaky. I took the three-in-a-row result from the builder's report. Two things I would do next: (1) add a shared beforeAll in parity.test.ts that creates alice, bob, the tokens and alice/pub, so the tests stop leaning on order through the tokens and the pub repo. (2) Fix the landing past a broken gate tests that fail under --randomize in test/gate*, which the builder named and left out; open an issue for them.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs