4697bbddd881c72cccb85b9ff0aacd769396b9d0 braney Thu Sep 10 07:34:35 2026 -0700 docent: record what evidence each regression test has, and count it A regression test written after the fix asserts the right answer, but nobody has watched it fail for the reason it exists, and a loose assertion in that state is indistinguishable from no test at all. Four of the 37 scripts here have actually been watched to flip. That was recorded only as prose in each script's header, so answering "how many of these are real regression tests" meant a grep and a read, and the number could not be quoted. Every script now carries a top-level `proof:` key, one quoted line per piece of evidence, ` -- `. docent.js reads only the keys it names off the parsed document, so this costs a run nothing. tests/proof.js reads them and tallies, wired up as `make proof` in the shared docentTest.mk. It exits 1 on a malformed line, an unknown level, or a line left unquoted -- that last one because nearly every note names a ticket and a bare # in an unquoted YAML scalar silently truncates the sentence at the ticket number, which is how the first pass of this change lost half its text. The levels, weakest first: assertion-only, xfail, sandbox-ab, server-flip, caught-regression. Today that reads 31 / 2 / 0 / 3 / 1. nightly.sh now records the flips it finds. An xfail that PASSES is the best evidence this suite produces -- the same server, the same fixtures, the same script, one real build apart -- and until now it arrived as a red mail and was thrown away with the log 60 days later. It is appended to /hive/users/braney/docentNightly/flips.log, one line per script ever, outside the checkout because --update resets the tree. The mail says what to do with it. The three flips that already happened (rm38272 2026-09-06, rm36212 2026-09-09, rm38310 2026-09-10) were recovered from the old logs and seeded there by hand. Full suite run after the change: 37 scripts, all ok. refs #38252 Co-Authored-By: Claude Opus 5 (1M context) diff --git src/hg/utils/docent/tests/regress/rm37326.docent.yaml src/hg/utils/docent/tests/regress/rm37326.docent.yaml index eeae69aaf17..74115e1c257 100644 --- src/hg/utils/docent/tests/regress/rm37326.docent.yaml +++ src/hg/utils/docent/tests/regress/rm37326.docent.yaml @@ -7,28 +7,31 @@ # _mouseOver), which reads "MIT Spec. Score: 62, Doench 2016: 92%, Moreno-Mateos: 79%" -- # not the scoreLabel ("MIT Guide Specificity Score") that trackDb shows on the details # page. 46 of the 117 guides in this window carry "Sequence is not unique in genome" # instead, so a guide with real scores has to be picked deliberately. # # Hover by TITLE, not by position. An earlier version used # `mouseover: {track: crispr10KTargets, at: chr17:43044494}`, which raised no tooltip: # `at:` sets x from the coordinate but forces y to the MIDDLE of the row, and in pack mode # this track is 324px of stacked guides, so the cursor landed between them. `title:` # matches the item's own map box, lands on its row wherever that row is, and makes docent # wait for THAT item's tooltip rather than settling for a neighbour's. # # The guide named here is chr17:43044497-43044520 and its mouseOver string is unique in # this window, so a match cannot be the wrong item. If the CRISPR data is rebuilt and its # scores change, this fails with the tooltip it did find, which is a readable break. +proof: + - "assertion-only 2026-09-05 -- written from the ticket after the fix had shipped" + target: genome-test db: hg38 position: chr17:43044295-43045295 reset: true fast: true steps: - go: chr17:43044295-43045295 - hide: all - track: {crispr10KTargets: pack} - expect: {rows: [crispr10KTargets], noText: "Warning/Error"} - mouseover: {track: crispr10KTargets, title: "MIT Spec. Score: 62, Doench 2016: 92%"} - expect: {tip: "MIT Spec. Score: 62, Doench 2016: 92%, Moreno-Mateos: 79%"}