UNPKG

1.38 kBMarkdownView Raw
1# @tractor-plugins/mocha-specs
2
3Plugin for [**tractor**](https://github.com/TradeMe/tractor) for creating E2E tests with [**Mocha**](https://mochajs.org/).
4
5[![Greenkeeper badge](https://badges.greenkeeper.io/phenomnomnominal/tractor-plugin-mocha-specs.svg)](https://greenkeeper.io/)
6[![npm version](https://img.shields.io/npm/v/@tractor-plugins/mocha-specs.svg)](https://www.npmjs.com/package/@tractor-plugins/mocha-specs)
7[![Code Climate](https://codeclimate.com/github/phenomnomnominal/tractor-plugin-mocha-specs/badges/gpa.svg)](https://codeclimate.com/github/phenomnomnominal/tractor-plugin-mocha-specs)
8[![Test Coverage](https://codeclimate.com/github/phenomnomnominal/tractor-plugin-mocha-specs/coverage.svg)](https://codeclimate.com/github/phenomnomnominal/tractor-plugin-mocha-specs/coverage)
9
10## How to install
11
12```sh
13npm install @tractor-plugins/mocha-specs --dev
14```
15
16## Config
17
18```javascript
19// tractor.conf.js
20module.exports = {
21 // ...
22 mochaSpecs: {
23
24 },
25 // ...
26};
27```
28
29For more information [see here](./docs/configuration.md)
30
31## Development
32
33To set up development:
34
35```sh
36npm install # install dependencies
37npm run dev # link dependencies
38tractor init
39```
40
41To run plugin:
42
43```sh
44npm run tractor:test # in one tab
45npm run tractor # in another tab
46```
47
48To run tests:
49
50```sh
51npm run tractor:test # in one tab
52npm run test:e2e # in another tab
53```