Repository navigation
test(ats): seed the whole pipeline; make an empty board fail instead of skip - #554
Merged
Merged
Conversation
…suite ## The seed 006 landed six applications across four stages with no source, no screening answers, no messages and no activity. Enough for a board to render, not enough for anything to be tested. Extends it with the missing stages (inquired, hired, rejected, withdrawn), source and screening data on the existing rows, a message thread, and — most of all — the stage history in core.application_activity. Nothing had ever written to that table, which is why the office UI hardcoded stageHistory to [] and time-to-hire could not compute (#531). The synthesised transitions give it something real to read. Idempotent: re-running changes nothing. Every column and constraint the SQL depends on was checked against the live local schema over PostgREST rather than assumed — I did not execute the seed, because another session is working in this database. ## The suite Each behavioural test calls `test.skip()` when its column is empty, so on an unseeded board all ten opt out and the run reports green having exercised nothing. Adds a "Fixture preconditions" block that *fails* instead, naming the seed command, so a missing fixture is a red suite rather than a silent pass. Also fixes 20 pre-existing type errors in the spec, down to zero: `test.skip("msg")` matched no Playwright overload — it takes `(condition, description)` and was relying on the string being truthy — and `let sourceColumn = KANBAN_COLUMNS.NEW` infers the literal `"new"`, so every later reassignment was an error. ## What this does not fix The suite still does not run at all, for two reasons outside this change. See the follow-up issue; flipping either on without the other just turns CI red. Refs #538
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#538, plus the reason it was worse than filed.
The seed
006 landed six applications across four stages with no source, no screening answers, no messages and no activity — enough for a board to render, not enough for anything to be tested.
Extended with the missing stages (
inquired,hired,rejected,withdrawn), source and screening data on the existing rows, a message thread, and the stage history incore.application_activity. Nothing had ever written to that table, which is why the office UI hardcodedstageHistoryto[]and time-to-hire couldn't compute — so #531 now has something real to read.Idempotent. Every column and constraint the SQL depends on was checked against the live schema over PostgREST.
I did not execute the seed — you're working in this database in another session, so I stayed read-only and didn't run
supa db seed,db reset, or kill any process.The suite
Each behavioural test calls
test.skip()when its column is empty, so on an unseeded board all ten opt out and the run reports green having exercised nothing. Added a "Fixture preconditions" block that fails instead, naming the seed command.Also fixed 20 pre-existing type errors in the spec, down to zero —
test.skip("msg")matches no Playwright overload (it takes(condition, description)and was relying on the string being truthy), andlet sourceColumn = KANBAN_COLUMNS.NEWinfers the literal"new".The part I did not do, deliberately
The suite doesn't run at all. Filed as #553:
testMatchis an explicit allow-list of 9 patterns. There are 15 office specs; two match. The kanban suite — ~30 tests, 617 lines — isn't one. Repo-wide Playwright finds 100 tests in 9 files.setupproject usestestDir: "./tests/e2e", butauth.setup.tslives attests/infrastructure/playwright/setup/setup/. So it matches nothing andtests/.auth/*.jsonis never created — every spec usingstorageStatewould fail at startup.These hide each other. Adding the spec to
testMatchalone makes it fail on the missing auth state; fixing the setup alone changes nothing visible. I didn't flip either: turning on ~30 never-run tests I can't execute locally (no dev server, no auth state, and I won't create one by entering credentials) would be shipping unverified.#538 said the suite "passes on an empty board." The truth is it never ran — which is why nobody noticed the board had been empty since the tRPC→SDK migration.
🤖 Generated with Claude Code