testdouble
Advanced tools
Comparing version 3.2.4 to 3.2.5
# Change Log | ||
## [v3.2.5](https://github.com/testdouble/testdouble.js/tree/v3.2.5) (2017-09-07) | ||
[Full Changelog](https://github.com/testdouble/testdouble.js/compare/v3.2.4...v3.2.5) | ||
**Closed issues:** | ||
- Missing support for async functions? \(Node 8\) [\#284](https://github.com/testdouble/testdouble.js/issues/284) | ||
- redacted [\#283](https://github.com/testdouble/testdouble.js/issues/283) | ||
- Stubbing priority [\#280](https://github.com/testdouble/testdouble.js/issues/280) | ||
**Merged pull requests:** | ||
- Upgrade lodash \(and support async functions\) [\#285](https://github.com/testdouble/testdouble.js/pull/285) ([rosston](https://github.com/rosston)) | ||
- Add previous/next links to documentation files [\#282](https://github.com/testdouble/testdouble.js/pull/282) ([randycoulman](https://github.com/randycoulman)) | ||
## [v3.2.4](https://github.com/testdouble/testdouble.js/tree/v3.2.4) (2017-08-06) | ||
@@ -4,0 +18,0 @@ [Full Changelog](https://github.com/testdouble/testdouble.js/compare/v3.2.3...v3.2.4) |
@@ -103,1 +103,4 @@ # Installing testdouble.js | ||
``` | ||
*** | ||
Next: [Purpose](2-howto-purpose.md#purpose) |
@@ -112,1 +112,5 @@ # Purpose | ||
situations by improving the API design of your adapters. | ||
*** | ||
Previous: [Installing testdouble.js](1-installation.md#installing-testdoublejs) | ||
Next: [Getting Started](3-getting-started.md#getting-started) |
@@ -357,1 +357,5 @@ # Getting Started | ||
* [Verifying invocations with `verify()`](6-verifying-invocations.md) | ||
*** | ||
Previous: [Purpose](2-howto-purpose.md#purpose) | ||
Next: [Creating Test Doubles](4-creating-test-doubles.md#creating-test-doubles) |
@@ -226,1 +226,5 @@ # Creating Test Doubles | ||
As you can see, there are a plethora of ways to create test doubles with testdouble.js, each designed to handle a different style of organizing JavaScript code. We recommend on landing on one consistent style (e.g. each module as one function) for each project, which in turn would encourage one consistent style of creating test doubles. This API is written to be flexible for a number of potential contexts across objects, but it has come at the cost of a large enough surface area that if any project were to make ample use of all or most of the above invocation styles, it would confuse readers. | ||
*** | ||
Previous: [Getting Started](3-getting-started.md#getting-started) | ||
Next: [Stubbing behavior](5-stubbing-results.md#stubbing-behavior) |
@@ -625,1 +625,5 @@ # Stubbing behavior | ||
and rest easy knowing that you already know exactly how to do it. | ||
*** | ||
Previous: [Creating Test Doubles](4-creating-test-doubles.md#creating-test-doubles#creating-test-doubles) | ||
Next: [Verifying interactions](6-verifying-invocations.md#verifying-interactions) |
@@ -376,1 +376,5 @@ # Verifying interactions | ||
dangerous writing isolated tests. | ||
*** | ||
Previous: [Stubbing behavior](5-stubbing-results.md#stubbing-behavior) | ||
Next: [Replacing Real Dependencies with Test Doubles](7-replacing-dependencies.md#replacing-real-dependencies-with-test-doubles) |
@@ -231,2 +231,4 @@ # Replacing Real Dependencies with Test Doubles | ||
*** | ||
Previous: [Verifying interactions](6-verifying-invocations.md#verifying-interactions) | ||
Next: [Custom argument matchers](8-custom-matchers.md#custom-argument-matchers) |
@@ -1,2 +0,2 @@ | ||
### Custom argument matchers | ||
# Custom argument matchers | ||
@@ -20,3 +20,3 @@ In addition to the built-in argument matchers described along with | ||
#### Example | ||
## Example | ||
@@ -48,3 +48,3 @@ Here's a naive implementation of a matcher named `isA` which will check whether | ||
#### td.matchers.create API | ||
## td.matchers.create API | ||
@@ -69,1 +69,5 @@ The `create` function takes a configuration object with the following properties | ||
[built-in matchers](src/matchers/index.coffee) provided by testdouble.js. | ||
*** | ||
Previous: [Replacing Real Dependencies with Test Doubles](7-replacing-dependencies.md#replacing-real-dependencies-with-test-doubles) | ||
Next: [Debugging with testdouble.js](9-debugging.md#debugging-with-testdoublejs) |
@@ -82,2 +82,4 @@ # Debugging with testdouble.js | ||
*** | ||
Previous: [Custom argument matchers](8-custom-matchers.md#custom-argument-matchers) | ||
Next: [Plugins](A-plugins.md#plugins) |
@@ -28,10 +28,10 @@ # Plugins | ||
Sometimes, it can be handy to have a ready-made shim to pull in and configure the | ||
Sometimes, it can be handy to have a ready-made shim to pull in and configure the | ||
library for various build tools. Here's what testdouble.js has so far: | ||
* [ember-cli-testdouble](https://github.com/isleofcode/ember-cli-testdouble) by | ||
[@AlexBlom](https://github.com/AlexBlom) provides a shim for easy importing of | ||
* [ember-cli-testdouble](https://github.com/isleofcode/ember-cli-testdouble) by | ||
[@AlexBlom](https://github.com/AlexBlom) provides a shim for easy importing of | ||
testdouble.js by Ember projects that using Ember CLI | ||
* [karma-testdouble](https://github.com/kahwee/karma-testdouble) by | ||
[@kahwee](https://github.com/kahwee) will configure | ||
* [karma-testdouble](https://github.com/kahwee/karma-testdouble) by | ||
[@kahwee](https://github.com/kahwee) will configure | ||
[Karma](https://karma-runner.github.io) to load test double's browser | ||
@@ -50,1 +50,5 @@ distribution | ||
[testdouble-timers](https://github.com/kuy/testdouble-timers). | ||
*** | ||
Previous: [Debugging with testdouble.js](9-debugging.md#debugging-with-testdoublejs) | ||
Next: [Frequently Asked Questions](B-frequently-asked-questions.md#frequently-asked-questions) |
@@ -46,1 +46,5 @@ # Frequently Asked Questions | ||
a stubbed invocation is also being verified. | ||
*** | ||
Previous: [Plugins](A-plugins.md#plugins) | ||
Next: [Configuration](C-configuration.md#configuration) |
@@ -20,1 +20,4 @@ # Configuration | ||
manage undoing the change yourself (e.g. in `beforeEach` and `afterEach` hooks). | ||
*** | ||
Previous: [Frequently Asked Questions](B-frequently-asked-questions.md#frequently-asked-questions) |
@@ -6,2 +6,2 @@ 'use strict'; | ||
}); | ||
exports.default = '3.2.4'; | ||
exports.default = '3.2.5'; |
{ | ||
"name": "testdouble", | ||
"version": "3.2.4", | ||
"version": "3.2.5", | ||
"description": "A minimal test double library for TDD with JavaScript", | ||
@@ -84,3 +84,3 @@ "homepage": "https://github.com/testdouble/testdouble.js", | ||
"es6-map": "^0.1.5", | ||
"lodash": "^4.15.0", | ||
"lodash": "^4.17.4", | ||
"quibble": "^0.5.1", | ||
@@ -87,0 +87,0 @@ "resolve": "^1.3.3", |
108
README.md
@@ -73,64 +73,64 @@ # testdouble.js | ||
1. [Installation](docs/1-installation.md#installing-testdoublejs) | ||
1. [for Node.js](docs/1-installation.md#for-use-in-nodejs-or-browserify) | ||
2. [for browsers](docs/1-installation.md#for-use-in-browsers) | ||
3. [initial configuration](docs/1-installation.md#configuring-testdoublejs-setting-up-in-your-test-suite) | ||
2. [Purpose of testdouble.js](docs/2-howto-purpose.md#background) | ||
1. [in unit tests](docs/2-howto-purpose.md#test-doubles-and-unit-tests) | ||
2. [in integration tests](docs/2-howto-purpose.md#test-doubles-and-integration-tests) | ||
1. [for Node.js](docs/1-installation.md#for-use-in-nodejs-or-browserify) | ||
2. [for browsers](docs/1-installation.md#for-use-in-browsers) | ||
3. [initial configuration](docs/1-installation.md#configuring-testdoublejs-setting-up-in-your-test-suite) | ||
2. [Purpose of testdouble.js](docs/2-howto-purpose.md#purpose) | ||
1. [in unit tests](docs/2-howto-purpose.md#test-doubles-and-unit-tests) | ||
2. [in integration tests](docs/2-howto-purpose.md#test-doubles-and-integration-tests) | ||
3. [Getting started tutorial](docs/3-getting-started.md#getting-started) | ||
4. [Creating test doubles](docs/4-creating-test-doubles.md#creating-test-doubles) | ||
1. [test double functions with `td.function()`](docs/4-creating-test-doubles.md#tdfunctionname) | ||
2. [test double objects with `td.object()`](docs/4-creating-test-doubles.md#tdobject) | ||
3. [test double constructors with `td.constructor()`](docs/4-creating-test-doubles.md#tdconstructor) | ||
1. [test double functions with `td.function()`](docs/4-creating-test-doubles.md#tdfunctionname) | ||
2. [test double objects with `td.object()`](docs/4-creating-test-doubles.md#tdobject) | ||
3. [test double constructors with `td.constructor()`](docs/4-creating-test-doubles.md#tdconstructor) | ||
5. [Stubbing responses](docs/5-stubbing-results.md#stubbing-behavior) | ||
1. [td.when() API](docs/5-stubbing-results.md#tdwhen) | ||
2. [equality argument matching](docs/5-stubbing-results.md#simple-precise-argument-stubbing) | ||
3. [one-liner stubbings](docs/5-stubbing-results.md#one-liner-stubbings) | ||
4. [stubbing sequential return values](docs/5-stubbing-results.md#stubbing-sequential-return-values) | ||
5. [argument matchers](docs/5-stubbing-results.md#loosening-stubbings-with-argument-matchers) | ||
1. [td.matchers.anything()](docs/5-stubbing-results.md#tdmatchersanything) | ||
2. [td.matchers.isA()](docs/5-stubbing-results.md#tdmatchersisa) | ||
3. [td.matchers.contains()](docs/5-stubbing-results.md#tdmatcherscontains) | ||
1. [matching strings](docs/5-stubbing-results.md#strings) | ||
2. [matching arrays](docs/5-stubbing-results.md#arrays) | ||
3. [matching objects](docs/5-stubbing-results.md#objects) | ||
4. [td.matchers.argThat()](docs/5-stubbing-results.md#tdmatchersargthat) | ||
5. [td.matchers.not()](docs/5-stubbing-results.md#tdmatchersnot) | ||
6. [Stubbing callback APIs](docs/5-stubbing-results.md#stubbing-callback-apis) | ||
7. [Stub exceptions with thenThrow](docs/5-stubbing-results.md#stub-exceptions-with-thenthrow) | ||
8. [Stub promises with thenResolve and thenReject](docs/5-stubbing-results.md#stub-promises-with-thenresolve-and-thenreject) | ||
9. [Stub side effects with thenDo](docs/5-stubbing-results.md#stub-side-effects-with-thendo) | ||
10. [Configuring stubbings](docs/5-stubbing-results.md#configuring-stubbings) | ||
1. [ignoreExtraArgs](docs/5-stubbing-results.md#ignoreextraargs) | ||
2. [times](docs/5-stubbing-results.md#times) | ||
3. [defer](docs/5-stubbing-results.md#defer) | ||
4. [delay](docs/5-stubbing-results.md#delay) | ||
1. [td.when() API](docs/5-stubbing-results.md#tdwhen) | ||
2. [equality argument matching](docs/5-stubbing-results.md#simple-precise-argument-stubbing) | ||
3. [one-liner stubbings](docs/5-stubbing-results.md#one-liner-stubbings) | ||
4. [stubbing sequential return values](docs/5-stubbing-results.md#stubbing-sequential-return-values) | ||
5. [argument matchers](docs/5-stubbing-results.md#loosening-stubbings-with-argument-matchers) | ||
1. [td.matchers.anything()](docs/5-stubbing-results.md#tdmatchersanything) | ||
2. [td.matchers.isA()](docs/5-stubbing-results.md#tdmatchersisa) | ||
3. [td.matchers.contains()](docs/5-stubbing-results.md#tdmatcherscontains) | ||
1. [matching strings](docs/5-stubbing-results.md#strings) | ||
2. [matching arrays](docs/5-stubbing-results.md#arrays) | ||
3. [matching objects](docs/5-stubbing-results.md#objects) | ||
4. [td.matchers.argThat()](docs/5-stubbing-results.md#tdmatchersargthat) | ||
5. [td.matchers.not()](docs/5-stubbing-results.md#tdmatchersnot) | ||
6. [Stubbing callback APIs](docs/5-stubbing-results.md#stubbing-callback-apis) | ||
7. [Stub exceptions with thenThrow](docs/5-stubbing-results.md#stub-exceptions-with-thenthrow) | ||
8. [Stub promises with thenResolve and thenReject](docs/5-stubbing-results.md#stub-promises-with-thenresolve-and-thenreject) | ||
9. [Stub side effects with thenDo](docs/5-stubbing-results.md#stub-side-effects-with-thendo) | ||
10. [Configuring stubbings](docs/5-stubbing-results.md#configuring-stubbings) | ||
1. [ignoreExtraArgs](docs/5-stubbing-results.md#ignoreextraargs) | ||
2. [times](docs/5-stubbing-results.md#times) | ||
3. [defer](docs/5-stubbing-results.md#defer) | ||
4. [delay](docs/5-stubbing-results.md#delay) | ||
6. [Verifying invocations](docs/6-verifying-invocations.md#verifying-interactions) | ||
1. [td.verify() API](docs/6-verifying-invocations.md#tdverify) | ||
2. [equality argument matching](docs/6-verifying-invocations.md#arguments) | ||
3. [argument matchers](docs/6-verifying-invocations.md#relaxing-verifications-with-argument-matchers) | ||
1. [td.matchers.anything()](docs/6-verifying-invocations.md#tdmatchersanything) | ||
2. [td.matchers.isA()](docs/6-verifying-invocations.md#tdmatchersisa) | ||
3. [td.matchers.contains()](docs/6-verifying-invocations.md#tdmatcherscontains) | ||
1. [matching strings](docs/6-verifying-invocations.md#strings) | ||
2. [matching arrays](docs/6-verifying-invocations.md#arrays) | ||
3. [matching objects](docs/6-verifying-invocations.md#objects) | ||
4. [td.matchers.argThat()](docs/6-verifying-invocations.md#tdmatchersargthat) | ||
4. [Argument captors](docs/6-verifying-invocations.md#multi-phase-assertions-with-argument-captors) | ||
5. [Configuring verifications](docs/6-verifying-invocations.md#configuring-verifications) | ||
1. [ignoreExtraArgs](docs/6-verifying-invocations.md#ignoreextraargs) | ||
2. [times](docs/6-verifying-invocations.md#times) | ||
1. [td.verify() API](docs/6-verifying-invocations.md#tdverify) | ||
2. [equality argument matching](docs/6-verifying-invocations.md#arguments) | ||
3. [argument matchers](docs/6-verifying-invocations.md#relaxing-verifications-with-argument-matchers) | ||
1. [td.matchers.anything()](docs/6-verifying-invocations.md#tdmatchersanything) | ||
2. [td.matchers.isA()](docs/6-verifying-invocations.md#tdmatchersisa) | ||
3. [td.matchers.contains()](docs/6-verifying-invocations.md#tdmatcherscontains) | ||
1. [matching strings](docs/6-verifying-invocations.md#strings) | ||
2. [matching arrays](docs/6-verifying-invocations.md#arrays) | ||
3. [matching objects](docs/6-verifying-invocations.md#objects) | ||
4. [td.matchers.argThat()](docs/6-verifying-invocations.md#tdmatchersargthat) | ||
4. [Argument captors](docs/6-verifying-invocations.md#multi-phase-assertions-with-argument-captors) | ||
5. [Configuring verifications](docs/6-verifying-invocations.md#configuring-verifications) | ||
1. [ignoreExtraArgs](docs/6-verifying-invocations.md#ignoreextraargs) | ||
2. [times](docs/6-verifying-invocations.md#times) | ||
7. [Replacing dependencies with test doubles](docs/7-replacing-dependencies.md#replacing-real-dependencies-with-test-doubles) | ||
1. [for Node.js](docs/7-replacing-dependencies.md#nodejs) | ||
2. [for Browser JS](docs/7-replacing-dependencies.md#browser) | ||
3. [td.replace() API](docs/7-replacing-dependencies.md#testdoublereplace-api) | ||
1. [for Node.js](docs/7-replacing-dependencies.md#nodejs) | ||
2. [for Browser JS](docs/7-replacing-dependencies.md#browser) | ||
3. [td.replace() API](docs/7-replacing-dependencies.md#testdoublereplace-api) | ||
8. [Writing custom argument matchers](docs/8-custom-matchers.md#custom-argument-matchers) | ||
9. [Debugging with testdouble.js](docs/9-debugging.md#debugging-with-testdoublejs) | ||
1. [td.explain() API](docs/9-debugging.md#tdexplainsometestdouble) | ||
1. [td.explain() API](docs/9-debugging.md#tdexplainsometestdouble) | ||
10. [Plugins](docs/A-plugins.md#plugins) | ||
1. [testdouble-chai](https://github.com/basecase/testdouble-chai) | ||
2. [testdouble-jasmine](https://github.com/BrianGenisio/testdouble-jasmine) | ||
1. [testdouble-chai](https://github.com/basecase/testdouble-chai) | ||
2. [testdouble-jasmine](https://github.com/BrianGenisio/testdouble-jasmine) | ||
11. [Frequently Asked Questions](docs/B-frequently-asked-questions.md#frequently-asked-questions) | ||
1. [Why doesn't `td.replace()` work with external CommonJS modules?](docs/B-frequently-asked-questions.md#why-doesnt-tdreplace-work-with-external-commonjs-modules) | ||
12. [Configuration](docs/C-configuration.md) | ||
1. [td.config](docs/C-configuration.md#tdconfig) | ||
1. [Why doesn't `td.replace()` work with external CommonJS modules?](docs/B-frequently-asked-questions.md#why-doesnt-tdreplace-work-with-external-commonjs-modules) | ||
12. [Configuration](docs/C-configuration.md#configuration) | ||
1. [td.config](docs/C-configuration.md#tdconfig) |
@@ -1,1 +0,1 @@ | ||
export default '3.2.4' | ||
export default '3.2.5' |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1696822
Updatedlodash@^4.17.4