entro-jest-flags
TypeScript icon, indicating that this package has built-in type declarations

1.2.0 • Public • Published

entro-jest-flags

A CLI that allows us to generate flags for jest form a json file. This can be used to change flags in conjunction with nodemon.

oclif Version Downloads/week License

Usage

If you create a .json file with the following entries,

config.json:

{
    "namePattern": "name pattern",
    "pathPattern": "path pattern"
}

And then you run, entro-jest-flags config.json, the output will be:

--testNamePattern="name pattern" --testPathPattern="path pattern"

So using nodemon, we can rerun jest tests using:

nodemon --watch=./config.json --exec npm run test

And then set the test script in your package.json to:

jest $(entro-jest-flags ./config.json) --watchAll --verbose
$ npm install -g entro-jest-flags
$ entro-jest-flags COMMAND
running command...
$ entro-jest-flags (-v|--version|version)
entro-jest-flags/1.2.0 linux-x64 node-v14.15.0
$ entro-jest-flags --help [COMMAND]
USAGE
  $ entro-jest-flags COMMAND
...

Readme

Keywords

Package Sidebar

Install

npm i entro-jest-flags

Weekly Downloads

1

Version

1.2.0

License

MIT

Unpacked Size

6.19 kB

Total Files

7

Last publish

Collaborators

  • entrostat-developer