Skip to content

Commit

Permalink
Add an example to the readme.
Browse files Browse the repository at this point in the history
  • Loading branch information
blakeembrey committed Mar 3, 2014
1 parent 7536145 commit 3802271
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,13 @@ npm install co-mocha --save-dev

## Usage

Add `--require co-mocha` to your `mocha.opts`.
Add `--require co-mocha` to your `mocha.opts`. Now you can write your tests using generators.

```js
it('should do something', function* () {
yield users.load(123);
});
```

## License

Expand Down

0 comments on commit 3802271

Please sign in to comment.