|
| 1 | +# Release Notes |
| 2 | + |
| 3 | +## 0.6.0 / 2015-04-24 |
| 4 | + |
| 5 | +Added `.spy.on` and `.spy.object` to easily make new spies, for example: |
| 6 | + |
| 7 | +```js |
| 8 | +// Returns `fs` but with readFile and readFileSync spied on |
| 9 | +var fs = chai.spy.object(fs, ['readFile', 'readFileSync']); |
| 10 | + |
| 11 | +// Shortcut for `fs.writeFile = chai.spy(fs.writeFile)` |
| 12 | +chai.spy.on(fs, 'writeFile'); |
| 13 | +``` |
| 14 | + |
| 15 | +Added new assertions: |
| 16 | + |
| 17 | + * `.called.min(n)/.at.least(n)` to assert a spy has been called a minimum of |
| 18 | + `n` many times. |
| 19 | + * `.called.max(n)/.at.most(n)` to assert that a spy has been called at most `n` |
| 20 | + number of times. |
| 21 | + |
| 22 | +### Community Contributions |
| 23 | + |
| 24 | +#### Code Features & Fixes |
| 25 | + |
| 26 | + * [#9](https://github.com/chaijs/chai/pull/9) Add support for component |
| 27 | + By [@pgherveou](https://github.com/pgherveou) |
| 28 | + |
| 29 | + * [#15](https://github.com/chaijs/chai/pull/15) Add `above`/`below`/`at.most`/ |
| 30 | + `at.least` call count assertions. |
| 31 | + By [@brandonhorst](https://github.com/brandonhorst) |
| 32 | + |
| 33 | + * [#20](https://github.com/chaijs/chai/pull/20) Fix output for `.called()` |
| 34 | + By [@Ryckes](https://github.com/Ryckes) |
| 35 | + |
| 36 | + * [#21](https://github.com/chaijs/chai/pull/21) Add `.spy.on` and `.spy.object` |
| 37 | + methods. |
| 38 | + By [@stalniy](https://github.com/stalniy) |
| 39 | + |
| 40 | +#### Documentation fixes |
| 41 | + |
| 42 | + * [#10](https://github.com/chaijs/chai/pull/10) Fix documentation with `once` |
| 43 | + By [@pgherveou](https://github.com/pgherveou) |
| 44 | + |
| 45 | + * [#16](https://github.com/chaijs/chai/pull/16) Add `.with` docs |
| 46 | + By [@plaxdan](https://github.com/plaxdan) |
| 47 | + |
| 48 | + * [#17](https://github.com/chaijs/chai/pull/17) Fix small typo in docs |
| 49 | + By [@Ryuno-Ki](https://github.com/Ryuno-Ki) |
| 50 | + |
| 51 | + * [#19](https://github.com/chaijs/chai/pull/19) Fix a handful of typos in |
| 52 | + README.md |
| 53 | + By [@sateffen](https://github.com/sateffen) |
| 54 | + |
| 55 | +## 0.5.1 / 2012-11-15 |
| 56 | + |
| 57 | +Small bugfix, fixing the output of the `.called(n)` assertion error. |
| 58 | + |
| 59 | +## 0.5.0 / 2012-11-14 |
| 60 | + |
| 61 | +A few new features: |
| 62 | + |
| 63 | + - Add `.with()` and `.exactly.with()` assertion for asserting what arguments |
| 64 | + a spy was called with. |
| 65 | + |
| 66 | +## 0.4.0 / 2012-10-09 |
| 67 | + |
| 68 | +Ensure spies return the value of their wrapped functions |
| 69 | + |
| 70 | +### Community Contributions |
| 71 | + |
| 72 | +#### Code Features & Fixes |
| 73 | + |
| 74 | + * [#5](https://github.com/chaijs/chai/pull/5) Make spies have a return value. |
| 75 | + By [@tregusti](https://github.com/tregusti) |
| 76 | + |
| 77 | +## 0.3.0 / 2012-07-11 |
| 78 | + |
| 79 | +Add ability for spies to have an (optional) name. |
| 80 | + |
| 81 | +### Community Contributions |
| 82 | + |
| 83 | +#### Code Features & Fixes |
| 84 | + |
| 85 | + * [#3](https://github.com/chaijs/chai/pull/3) Add an optional name to spies |
| 86 | + By [@tregusti](https://github.com/tregusti) |
| 87 | + |
| 88 | +#### Documentation fixes |
| 89 | + |
| 90 | + * [#2](https://github.com/chaijs/chai-spies/pull/2) Fix typos in `called.twice` |
| 91 | + assertion |
| 92 | + By [@tregusti](https://github.com/tregusti) |
| 93 | + |
| 94 | + * [#3](https://github.com/chaijs/chai-spies/pull/2) Fix various typos |
| 95 | + By [@tregusti](https://github.com/tregusti) |
| 96 | + |
| 97 | + |
| 98 | +## 0.2.3 / 2012-07-09 |
| 99 | + |
| 100 | +Small bugfixes, improving the AMD wraper |
| 101 | + |
| 102 | +## 0.2.2 / 2012-05-17 |
| 103 | + |
| 104 | +Few minor bugfixes, no new features. |
| 105 | + |
| 106 | +## 0.2.1 / 2012-05-17 |
| 107 | + |
| 108 | +Spies now mimic length of original function. |
| 109 | + |
| 110 | +## 0.2.0 / 2012-05-16 |
| 111 | + |
| 112 | +Add Chai 1.0.0 compatibility. |
| 113 | + |
| 114 | +### Community Contributions |
| 115 | + |
| 116 | +#### Documentation fixes |
| 117 | + |
| 118 | + * [#1](https://github.com/chaijs/chai-spies/pull/1) Fix README typos and |
| 119 | + missing link |
| 120 | + By [@JamesMaroney](https://github.com/JamesMaroney) |
| 121 | + |
| 122 | +## 0.1.0 / 2012-02-13 |
| 123 | + |
| 124 | +Initial release |
0 commit comments