github remix-run/remix test@1.1.0
test v1.1.0

latest releases: ui@0.13.1, remix@3.2.0, static-middleware@1.0.2...
4 hours ago

Minor Changes

  • Add new APIs to the mock function context for both mock and t.mock: (#12097)

    • mockImplementation(implementation) changes the default implementation.
    • mockImplementationOnce(implementation, onCall?) replaces one call at a zero-based index, defaulting to the next call.
    • resetCalls() clears the call history.
    • callCount() returns the number of recorded invocations, including calls still executing.
    • restore() restores a standalone mock's original implementation.

    Replacement controls preserve generic and overloaded function signatures. Test context mocks restore in registration order alongside cleanup callbacks, even after failures. Cleanup errors retain their original stack traces and are reported alongside test failures.

Patch Changes

  • Fix syntax errors in browser tests that dynamically import modules by preserving quotes around rewritten module URLs. (#12102)

  • Fix browser test runs in WebKit stalling until the progress timeout once earlier files' results fill the runner page. The running file was placed below those results, out of view, where WebKit throttles its timers. It now runs at the top of the page. (#12162)

Don't miss a new remix release

NewReleases is sending notifications on new releases.