Skip to content

v0.2.7 — test/test-setup preload file

Choose a tag to compare

@brainkim brainkim released this 28 Jul 17:14
· 68 commits to main since this release

Added

  • Test setup/preload file — If test/test-setup.{ts,tsx,js,jsx} exists, it is imported once at the top of the generated test entry, before any test files, on every platform (bun, node, browsers). Use it to register global beforeEach/afterEach hooks, install polyfills, or do environment setup that must run ahead of the suite. No config or flag — a single conventional file, discovered like the tests and excluded from the run so it isn't executed as a test. Platform-specific behavior lives inside the one file via runtime detection (e.g. if (typeof Bun !== "undefined") { ... }), since all tests share a single bundle per platform. Resolves #13.