Skip to content

Commit bada58f

Browse files
committed
test(spec): the transactions tombstone pin discriminates its own subject
`packages/spec/src/data/driver.test.ts` pinned the `transactions` retired-key prescription with a regex requiring only that `METHOD PRESENCE` and `beginTransaction` appear somewhere in the thrown message. #18890 rewrote that prescription's opening from "gated on METHOD PRESENCE" to "gated on the DRIVER'S DECLARATION, no longer on METHOD PRESENCE alone" — and the old regex matches BOTH. Reverting the prescription to the now-false sentence kept the test green, so the pin could not fail on the one shape it exists to catch. The title said "points at method presence", which is the old world too. Anchor on the two things #18890 made load-bearing instead: the negation (`no longer on METHOD PRESENCE`) and the predicate that replaced presence (`driverSupportsTransactions`). `beginTransaction` and `Delete the key` stay, so nothing the old pin covered is dropped. Deliberately NOT a ban on the phrase `METHOD PRESENCE`: `schemaSync`'s own "Schema sync is gated on METHOD PRESENCE" sentence in driver.zod.ts is true of the runtime today and is untouched. Test-only. No runtime file, no published surface. Claude-Session: https://claude.ai/code/session_01JbZnqu8bt6YqfJsr9vaFb3 Co-authored-by: Claude <noreply@anthropic.com>
1 parent 0ec8185 commit bada58f

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

‎packages/spec/src/data/driver.test.ts‎

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,16 @@ describe('[#4634] the 31 inert capability bits are tombstoned, not stripped', ()
121121
);
122122
});
123123

124-
it('the transactions prescription points at method presence, and says the live bit is not it restored', () => {
124+
it('the transactions prescription points at the DECLARATION gate, not method presence alone, and says the live bit is not it restored', () => {
125+
// [#18996] Anchored on what #18890 made load-bearing: the NEGATION and the
126+
// predicate that replaced method presence. An anchor on `METHOD PRESENCE`
127+
// alone matched this prescription's PREVIOUS, now-false opening ('gated on
128+
// METHOD PRESENCE — `driver.beginTransaction`') exactly as happily as the
129+
// true one, so it could not fail on the one shape it exists to catch. ⛔ Not
130+
// a ban on the phrase — `schemaSync`'s own 'gated on METHOD PRESENCE'
131+
// sentence is true of the runtime and stays.
125132
expect(() => DriverCapabilitiesSchema.parse({ transactions: true })).toThrow(
126-
/DriverCapabilities\.transactions.*removed.*METHOD PRESENCE.*beginTransaction.*Delete the key/s,
133+
/DriverCapabilities\.transactions.*removed.*no longer on METHOD PRESENCE.*driverSupportsTransactions.*beginTransaction.*Delete the key/s,
127134
);
128135
// [#18063] The trap this sentence exists to close: a reader who sees a live
129136
// `transactionsUnsupported` and concludes the retired key came back. It did

0 commit comments

Comments
 (0)