@martindzejky/promise-mock
TypeScript icon, indicating that this package has built-in type declarations

1.0.5 • Public • Published

promise-mock

GitHub tag npm Tests

Synchronous promise mock for tests. Implemented using Typescript so types are provided with the library. Also, the mock class implements Promise interface so you can use it wherever a real Promise is required.

Forked and inspired by @slavik57's promise-sync. I felt that his original implementation is a bit outdated and, more importanty, it does not implement Promise interface so it is painful to use in places where a real promise is required. (See slavik57/promise-sync#15 for my original issue)

Dependencies (0)

    Dev Dependencies (7)

    Package Sidebar

    Install

    npm i @martindzejky/promise-mock

    Weekly Downloads

    27

    Version

    1.0.5

    License

    SEE LICENSE IN LICENSE.md

    Unpacked Size

    14.4 kB

    Total Files

    13

    Last publish

    Collaborators

    • martindzejky