0.0.1 • Published 9 years ago
forgiven-promise v0.0.1
forgiven-promise
Forgiven extension for recording promises returned from setup steps
Usage
npm install --save-dev forgiven forgiven-mocha forgiven-promiseimport {
create,
} from 'forgiven';
import {
mocha,
} from 'forgiven-mocha';
import {
promise,
} from 'forgiven-promise';
global.given = create(mocha, {
promise: promise,
});
const context = {};
given.a.promise.as(context, 'promise').from(() => Promise.reject(new Error('FAIL')))
.then(() => context.promise.should.be.rejectedWith('FAIL'))
.end();Contributing
Run unit tests and build before pushing/opening a pull request.
npm test- lint and testnpm start- watch and build, etc with alarmistnpm run build- run tests then buildnpm run watch- watch for changes and run buildnpm run ci- run build and submit coverage to coveralls
0.0.1
9 years ago