7.0.5 • Published 7 months ago

mocha-play v7.0.5

Weekly downloads
4,867
License
MIT
Repository
github
Last release
7 months ago

mocha-play

Build Status npm version

Run mocha tests in chromium, using webpack and playwright.

Installation

Install mocha-play as a dev dependency:

npm i mocha-play --save-dev

mocha-play expects mocha, @playwright/browser-chromium, and webpack to also be installed in the project.

Usage

A CLI named mocha-play is available after installation:

mocha-play [options] <glob ...>

For example:

mocha-play "test/**/*.spec.js"
mocha-play "test/**/*.spec.ts" -c webpack.config.js

CLI Options

-v, --version                       output the version number
-c, --webpack-config <config file>  webpack configuration file to bundle with
-w, --watch                         never-closed, open browser, open-devtools, html-reporter session
-l, --list-files                    list found test files
-t, --timeout <ms>                  mocha timeout in ms (default: 2000)
-p, --port <number>                 port to start the http server with (default: 3000)
--reporter <spec/html/dot/...>      mocha reporter to use (default: "spec")
--ui <bdd|tdd|qunit|exports>        mocha user interface (default: "bdd")
-h, --help                          display help for command

License

MIT

7.0.5

7 months ago

7.0.4

9 months ago

7.0.3

10 months ago

7.0.2

10 months ago

6.0.1

1 year ago

6.0.2

1 year ago

7.0.0

1 year ago

7.0.1

1 year ago

6.0.0

1 year ago

5.0.1

2 years ago

5.0.0

2 years ago

4.1.2

2 years ago

4.1.1

2 years ago

4.1.0

2 years ago

4.0.0

2 years ago

3.1.0

3 years ago

3.0.2

3 years ago

3.0.1

3 years ago

3.0.0

3 years ago

2.0.3

3 years ago

2.0.2

3 years ago

2.0.1

3 years ago

2.0.0

3 years ago

1.0.1

4 years ago

1.0.0

4 years ago