Skip to content

meeshkan/unmock-jest-runner

master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 

unmock-jest-runner

CircleCI Status

With the Unmock runner, you can run any test multiple times with different potential outcomes from the API.

This package holds the core functions for the Jest configuration of the runner.

Default

By default, the runner is set to run your test 20 times.

Usage

The unmock-jest-runner can be installed via NPM or Yarn:

npm install -D unmock-jest-runner
yarn add unmock-jest-runner

Once installed, the runner can be imported as a default and used as a wrapper for your tests:

const runner = require("unmock-jest-runner").default;

test("my API always works as expected", runner(async () => {
  const res = await myApiFunction();
  // some expectations
}));

Beyond Jest

As of now, Jest is the only package available for the Unmock runner.

However, we're currently building out support for Mocha and QUnit. You can follow the progress of those implementations in the corresponding issues.

About

Jest configuration for the unmock-js runner

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •