japa-ts-mock
v1.0.1
Published
A mock library built on top of ts-mockito
Downloads
1
Readme
japa-ts-mock
A mock library built on top of ts-mockito
Installation
Install package from npm registry
npm i japa-ts-mock
Usage
You can use this plugin with the @japa/runner.
import { mocker } from 'japa-ts-mock'
import { configure } from '@japa/runner'
configure({
plugins: [mocker()]
})
In japa-types.ts write this:
import { mocker } from 'japa-ts-mock'
declare module '@japa/runner' {
interface TestContext {
mocker: Mocker
}
}