babel-plugin-s2s-jest-unit-test-case

0.2.9 • Public • Published

babel-plugin-s2s-jest-unit-test-case

s2s plugin: create jest test case from source

Install

$ npm install --save-dev babel-plugin-s2s-jest-unit-test-case

Example

target.js

export function sum(a, b) {
  return a + b
}

IN:

// this is test file

OUT:

// this is test file
import { sum } from './target'

test('sum', () => {
  const result = sum()
  expect(result).toBe(null)
})

Options

from

type: string
required: true

Set target.js path

If you use s2s, you don't use this option. s2s handle it automatically.

Readme

Keywords

none

Package Sidebar

Install

npm i babel-plugin-s2s-jest-unit-test-case

Weekly Downloads

3

Version

0.2.9

License

MIT

Unpacked Size

5.98 kB

Total Files

6

Last publish

Collaborators

  • akameco