Skip to content

v0.2.13 — snapshot wrapper no longer drops bun test.todo/skip/only

Choose a tag to compare

@brainkim brainkim released this 11 Aug 23:16
· 60 commits to main since this release

Fixed

  • Snapshot test wrapper no longer drops test.todo/.skip/.only/.each on bun. 0.2.12's toMatchSnapshot wraps describe/test/it to track the current test name, copying their sub-methods with Object.getOwnPropertyNames. bun exposes those sub-methods on the prototype, not as own properties, so the copy found only length/name and dropped them all — every bun test file calling test.todo(...) (etc.) then threw undefined is not a function and aborted the rest of that file, silently reducing the bun test count. (node exposes them as own properties, so node was unaffected.) The wrapper now walks the prototype chain, covering both runtimes.