May 2 · 3 min read · Originally published at recca0120.github.io All tests pass, but the terminal is full of red console.error output. This is common and easy to ignore — the tests passed, after all. But those errors don't appear out of nowhere. Something went wrong; nob...
Join discussionApr 28 · 6 min read · Originally published at recca0120.github.io How do you test a Node.js service that operates on the filesystem? The obvious approach is to create real files under /tmp, run the tests, then clean up. But that comes with problems: slow I/O, inconsistent...
Join discussionApr 19 · 6 min read · Originally published at recca0120.github.io The previous posts covered [DI + Fake + in-memory]({{< ref "/post/di-fake-in-memory-testing" >}}) and [sharing Fakes across a monorepo]({{< ref "/post/monorepo-shared-fake-testing" >}}). That approach has o...
Join discussionApr 19 · 7 min read · Originally published at recca0120.github.io The previous post covered [DI + Fake + in-memory basics]({{< ref "/post/di-fake-in-memory-testing" >}}). This one takes it further, into a scenario most testing tutorials ignore: how frontend, backend, and ...
Join discussionApr 19 · 6 min read · Originally published at recca0120.github.io The most common testing pattern I see looks like this: test('saves user data', () => { const mockStorage = { set: vi.fn(), get: vi.fn().mockReturnValue(null), }; const service = new UserServic...
Join discussionApr 7 · 2 min read · Coming from a background of Jest, Vitest, or Mocha, you'll find Rust's built-in testing suite incredibly refreshing. No extra dependencies are needed for basic unit testing! Think of Rust Testing as a Quality Contract. By writing tests, you are "Sign...
Join discussionMar 4 · 5 min read · Jest has been the default JavaScript test runner for years. But it was designed for CommonJS and requires significant configuration to handle modern ESM, TypeScript, and Vite projects. Vitest was built from the start for the modern JavaScript ecosyst...
Join discussionMar 3 · 6 min read · Testing Frameworks Compared: Jest, Vitest, Bun Test, and Playwright Choosing a test framework used to be simple: you picked Jest. Now there are genuinely good alternatives, each with different strengths. This guide compares the main options, covers d...
Join discussion