Skip to content
Browse files

removed node_modules

  • Loading branch information...
1 parent 33f7837 commit e38dcaa2dc0c6cc0a11db8fd9b6d593c0d05117a @davemckenna01 committed Apr 3, 2012
Showing with 1 addition and 16,433 deletions.
  1. +1 −1 .gitignore
  2. +0 −1 node_modules/.bin/_mocha
  3. +0 −1 node_modules/.bin/mocha
  4. +0 −3 node_modules/chai/.npmignore
  5. +0 −7 node_modules/chai/.travis.yml
  6. +0 −338 node_modules/chai/History.md
  7. +0 −45 node_modules/chai/Makefile
  8. +0 −97 node_modules/chai/README.md
  9. +0 −2,223 node_modules/chai/chai.js
  10. +0 −333 node_modules/chai/coverage.html
  11. +0 −3 node_modules/chai/index.js
  12. +0 −581 node_modules/chai/lib-cov/assertion.js
  13. +0 −59 node_modules/chai/lib-cov/chai.js
  14. +0 −54 node_modules/chai/lib-cov/error.js
  15. +0 −281 node_modules/chai/lib-cov/interface/assert.js
  16. +0 −17 node_modules/chai/lib-cov/interface/expect.js
  17. +0 −92 node_modules/chai/lib-cov/interface/should.js
  18. +0 −182 node_modules/chai/lib-cov/utils/eql.js
  19. +0 −453 node_modules/chai/lib-cov/utils/inspect.js
  20. +0 −1,015 node_modules/chai/lib/assertion.js
  21. +0 −33 node_modules/chai/lib/chai.js
  22. +0 −33 node_modules/chai/lib/error.js
  23. +0 −619 node_modules/chai/lib/interface/assert.js
  24. +0 −12 node_modules/chai/lib/interface/expect.js
  25. +0 −56 node_modules/chai/lib/interface/should.js
  26. +0 −100 node_modules/chai/lib/utils/eql.js
  27. +0 −270 node_modules/chai/lib/utils/inspect.js
  28. +0 −45 node_modules/chai/package.json
  29. +0 −112 node_modules/chai/support/compile.js
  30. +0 −4 node_modules/chai/support/prefix.js
  31. +0 −3 node_modules/chai/support/suffix.js
  32. +0 −331 node_modules/chai/test/assert.js
  33. +0 −23 node_modules/chai/test/browser/docs.html
  34. +0 −23 node_modules/chai/test/browser/index.html
  35. +0 −35 node_modules/chai/test/configuration.js
  36. +0 −526 node_modules/chai/test/expect.js
  37. +0 −26 node_modules/chai/test/plugins.js
  38. +0 −532 node_modules/chai/test/should.js
  39. +0 −5 node_modules/mocha/.npmignore
  40. +0 −5 node_modules/mocha/.travis.yml
  41. +0 −310 node_modules/mocha/History.md
  42. +0 −22 node_modules/mocha/LICENSE
  43. +0 −118 node_modules/mocha/Makefile
  44. +0 −34 node_modules/mocha/Readme.md
  45. +0 −3,916 node_modules/mocha/_mocha.js
  46. +0 −345 node_modules/mocha/bin/_mocha
  47. +0 −32 node_modules/mocha/bin/mocha
  48. +0 −334 node_modules/mocha/coverage.html
  49. +0 −16 node_modules/mocha/editors/JavaScript mocha.tmbundle/Snippets/bdd - after each.tmSnippet
  50. +0 −16 node_modules/mocha/editors/JavaScript mocha.tmbundle/Snippets/bdd - after.tmSnippet
  51. +0 −16 node_modules/mocha/editors/JavaScript mocha.tmbundle/Snippets/bdd - before each.tmSnippet
  52. +0 −16 node_modules/mocha/editors/JavaScript mocha.tmbundle/Snippets/bdd - before.tmSnippet
  53. +0 −16 node_modules/mocha/editors/JavaScript mocha.tmbundle/Snippets/bdd - it.tmSnippet
  54. +0 −16 node_modules/mocha/editors/JavaScript mocha.tmbundle/Snippets/untitled.tmSnippet
  55. +0 −19 node_modules/mocha/editors/JavaScript mocha.tmbundle/info.plist
  56. BIN node_modules/mocha/images/error.png
  57. BIN node_modules/mocha/images/ok.png
  58. +0 −4 node_modules/mocha/index.js
  59. +0 −6 node_modules/mocha/lib/browser/debug.js
  60. 0 node_modules/mocha/lib/browser/diff.js
  61. +0 −178 node_modules/mocha/lib/browser/events.js
  62. 0 node_modules/mocha/lib/browser/fs.js
  63. 0 node_modules/mocha/lib/browser/path.js
  64. +0 −125 node_modules/mocha/lib/browser/progress.js
  65. +0 −8 node_modules/mocha/lib/browser/tty.js
  66. +0 −55 node_modules/mocha/lib/context.js
  67. +0 −31 node_modules/mocha/lib/hook.js
  68. +0 −91 node_modules/mocha/lib/interfaces/bdd.js
  69. +0 −60 node_modules/mocha/lib/interfaces/exports.js
  70. +0 −5 node_modules/mocha/lib/interfaces/index.js
  71. +0 −91 node_modules/mocha/lib/interfaces/qunit.js
  72. +0 −94 node_modules/mocha/lib/interfaces/tdd.js
  73. +0 −176 node_modules/mocha/lib/mocha.js
  74. +0 −319 node_modules/mocha/lib/reporters/base.js
  75. +0 −74 node_modules/mocha/lib/reporters/doc.js
  76. +0 −62 node_modules/mocha/lib/reporters/dot.js
  77. +0 −44 node_modules/mocha/lib/reporters/html-cov.js
  78. +0 −211 node_modules/mocha/lib/reporters/html.js
  79. +0 −17 node_modules/mocha/lib/reporters/index.js
  80. +0 −149 node_modules/mocha/lib/reporters/json-cov.js
  81. +0 −61 node_modules/mocha/lib/reporters/json-stream.js
  82. +0 −70 node_modules/mocha/lib/reporters/json.js
  83. +0 −97 node_modules/mocha/lib/reporters/landing.js
  84. +0 −64 node_modules/mocha/lib/reporters/list.js
  85. +0 −111 node_modules/mocha/lib/reporters/markdown.js
  86. +0 −37 node_modules/mocha/lib/reporters/min.js
  87. +0 −85 node_modules/mocha/lib/reporters/progress.js
  88. +0 −87 node_modules/mocha/lib/reporters/spec.js
  89. +0 −63 node_modules/mocha/lib/reporters/tap.js
  90. +0 −56 node_modules/mocha/lib/reporters/teamcity.js
  91. +0 −50 node_modules/mocha/lib/reporters/templates/coverage.jade
  92. +0 −13 node_modules/mocha/lib/reporters/templates/menu.jade
  93. +0 −34 node_modules/mocha/lib/reporters/templates/script.html
Sorry, we could not display the entire diff because it was too big.
View
2 .gitignore
@@ -1,4 +1,4 @@
.DS_Store
*.swp
todo.txt
-
+node_modules/
View
1 node_modules/.bin/_mocha
View
1 node_modules/.bin/mocha
View
3 node_modules/chai/.npmignore
@@ -1,3 +0,0 @@
-.DS_Store
-.git*
-docs/
View
7 node_modules/chai/.travis.yml
@@ -1,7 +0,0 @@
-language: node_js
-node_js:
- - 0.4
- - 0.6
-branches:
- only:
- - master
View
338 node_modules/chai/History.md
@@ -1,338 +0,0 @@
-
-0.5.2 / 2012-03-21
-==================
-
- * browser build
- * Merge branch 'feature/assert-fail'
- * Added assert.fail. Closes #40
- * Merge branch 'bug/operator-msg'
- * better error message for assert.operator. Closes #39
- * version notes
-
-0.5.1 / 2012-03-14
-==================
-
- * chai.fail no longer exists
- * Merge branch 'feature/assertdefined'
- * Added asset#isDefined. Closes #37.
- * dev docs update for Assertion#assert
-
-0.5.0 / 2012-03-07
-==================
-
- * [bug] on inspect of reg on n 0.4.12
- * Merge branch 'bug/33-throws'
- * Merge pull request #35 from logicalparadox/empty-object
- * browser build
- * updated #throw docs
- * Assertion#throw `should` tests updated
- * Assertion#throw `expect` tests
- * Should interface supports multiple throw parameters
- * Update Assertion#throw to support strings and type checks.
- * Add more tests for `empty` in `should`.
- * Add more tests for `empty` in `expect`.
- * Merge branch 'master' into empty-object
- * don't switch act/exp
- * Merge pull request #34 from logicalparadox/assert-operator
- * Update the compiled verison.
- * Add `assert.operator`.
- * Notes on messages. #22
- * browser build
- * have been test
- * below tests
- * Merge branch 'feature/actexp'
- * browser build
- * remove unnecessary fail export
- * full support for actual/expected where relevant
- * Assertion.assert support expected value
- * clean up error
- * Update the compiled version.
- * Add object & sane arguments support to `Assertion#empty`.
-
-0.4.2 / 2012-02-28
-==================
-
- * fix for `process` not available in browser when used via browserify. Closes #28
- * Merge pull request #31 from joliss/doc
- * Document that "should" works in browsers other than IE
- * Merge pull request #30 from logicalparadox/assert-tests
- * Update the browser version of chai.
- * Update `assert.doesNotThrow` test in order to check the use case when type is a string.
- * Add test for `assert.ifError`.
- * Falsey -> falsy.
- * Full coverage for `assert.throws` and `assert.doesNotThrow`.
- * Add test for `assert.doesNotThrow`.
- * Add test for `assert.throws`.
- * Add test for `assert.length`.
- * Add test for `assert.include`.
- * Add test for `assert.isBoolean`.
- * Fix the implementation of `assert.isNumber`.
- * Add test for `assert.isNumber`.
- * Add test for `assert.isString`.
- * Add test for `assert.isArray`.
- * Add test for `assert.isUndefined`.
- * Add test for `assert.isNotNull`.
- * Fix `assert.isNotNull` implementation.
- * Fix `assert.isNull` implementation.
- * Add test for `assert.isNull`.
- * Add test for `assert.notDeepEqual`.
- * Add test for `assert.deepEqual`.
- * Add test for `assert.notStrictEqual`.
- * Add test for `assert.strictEqual`.
- * Add test for `assert.notEqual`.
-
-0.4.1 / 2012-02-26
-==================
-
- * Merge pull request #27 from logicalparadox/type-fix
- * Update the browser version.
- * Add should tests for type checks.
- * Add function type check test.
- * Add more type checks tests.
- * Add test for `new Number` type check.
- * Fix type of actual checks.
-
-0.4.0 / 2012-02-25
-==================
-
- * docs and readme for upcoming 0.4.0
- * docs generated
- * putting coverage and tests for docs in docs/out/support
- * make docs
- * makefile copy necessary resources for tests in docs
- * rename configuration test
- * Merge pull request #21 from logicalparadox/close-to
- * Update the browser version.
- * Update `closeTo()` docs.
- * Add `Assertion.closeTo()` method.
- * Add `.closeTo()` should test.
- * Add `.closeTo()` expect test.
- * Merge pull request #20 from logicalparadox/satisfy
- * Update the browser version.
- * `..` -> `()` in `.satisfy()` should test.
- * Update example for `.satisfy()`.
- * Update the compiled browser version.
- * Add `Assertion.satisfy()` method.
- * Add `.satisfy()` should test.
- * Add `.satisfy()` expect test.
- * Merge pull request #19 from logicalparadox/respond-to
- * Update the compiled browser version.
- * Add `respondTo` Assertion.
- * Add `respondTo` should test.
- * Add `respondTo` expect test.
- * Merge branch 'feature/coverage'
- * mocha coverage support
- * doc contributors
- * README contributors
-
-0.3.4 / 2012-02-23
-==================
-
- * inline comment typos for #15
- * Merge branch 'refs/heads/jeffbski-configErrorStackCompat'
- * includeStack documentation for all interfaces
- * suite name more generic
- * Update test to be compatible with browsers that do not support err.stack
- * udpated compiled chai.js and added to browser tests
- * Allow inclusion of stack trace for Assert error messages to be configurable
- * docs sharing buttons
- * sinon-chai link
- * doc updates
- * read me updates include plugins
-
-0.3.3 / 2012-02-12
-==================
-
- * Merge pull request #14 from jfirebaugh/configurable_properties
- * Make Assertion.prototype properties configurable
-
-0.3.2 / 2012-02-10
-==================
-
- * codex version
- * docs
- * docs cleanup
-
-0.3.1 / 2012-02-07
-==================
-
- * node 0.4.x compat
-
-0.3.0 / 2012-02-07
-==================
-
- * Merge branch 'feature/03x'
- * browser build
- * remove html/json/headers testign
- * regex error.message testing
- * tests for using plugins
- * Merge pull request #11 from domenic/master
- * Make `chai.use` a no-op if the function has already been used.
-
-0.2.4 / 2012-02-02
-==================
-
- * added in past tense switch for `been`
-
-0.2.3 / 2012-02-01
-==================
-
- * try that again
-
-0.2.2 / 2012-02-01
-==================
-
- * added `been` (past of `be`) alias
-
-0.2.1 / 2012-01-29
-==================
-
- * added Throw, with a capital T, as an alias to `throw` (#7)
-
-0.2.0 / 2012-01-26
-==================
-
- * update gitignore for vim *.swp
- * Merge branch 'feature/plugins'
- * browser build
- * interfaces now work with use
- * simple .use function. See #9.
- * readme notice on browser compat
-
-0.1.7 / 2012-01-25
-==================
-
- * added assert tests to browser test runner
- * browser update
- * `should` interface patch for primitives support in FF
- * fix isObject() Thanks @milewise
- * travis only on branch `master`
- * add instanceof alias `instanceOf`. #6
- * some tests for assert module
-
-0.1.6 / 2012-01-02
-==================
-
- * commenting for assert interface
- * updated codex dep
-
-0.1.5 / 2012-01-02
-==================
-
- * browser tests pass
- * type in should.not.equal
- * test for should (not) exist
- * added should.exist and should.not.exist
- * browser uses tdd
- * convert tests to tdd
-
-0.1.4 / 2011-12-26
-==================
-
- * browser lib update for new assert interface compatiblitiy
- * inspect typos
- * added strict equal + negatives and ifError
- * interface assert had doesNotThrow
- * added should tests to browser
- * new expect empty tests
- * should test browser compat
- * Fix typo for instanceof docs. Closes #3 [ci skip]
-
-0.1.3 / 2011-12-18
-==================
-
- * much cleaner reporting string on error.
-
-0.1.2 / 2011-12-18
-==================
-
- * [docs] for upcoming 0.1.2
- * browser version built with pre/suffix … all tests passing
- * make / compile now use prefix/suffix correctly
- * code clean
- * prefix/suffix to wrap browser output to prevent conflicts with other `require` methods.
- * Merge branch 'feature/should4xcompatibility'
- * compile for browser tests.. all pass
- * added header/status/html/json
- * throw tests
- * should.throw & should.not.throw shortcuts
- * improved `throw` type detection and messaging
- * contain is now `include` … keys modifier is now `contain`
- * removed object() test
- * removed #respondTo
- * Merge branch 'bug/2'
- * replaced __defineGetter__ with defineProperty for all uses
- * [docs] change mp tracking code
- * docs site updated with assert (TDD) interface
- * updated doc comments for assert interface
-
-0.1.1 / 2011-12-16
-==================
-
- * docs ready for upcoming 0.1.1
- * readme image fixed [ci skip]
- * more readme tweaks [ci skip]
- * réadmet image fixed [ci skip]
- * documentation
- * codex locked in version 0.0.5
- * more comments to assertions for docs
- * assertions fully commented, browser library updated
- * adding codex as doc dependancy
- * prepping for docs
- * assertion component completely commented for documentation
- * added exist test
- * var expect outside of browser if check
- * added keywords to package.json
-
-0.1.0 / 2011-12-15
-==================
-
- * failing on purpose successful .. back to normal
- * testing travis failure
- * assert#arguments getter
- * readme typo
- * updated README
- * added travis and npmignore
- * copyright notices … think i got them all
- * moved expect interface to own file for consistency
- * assert ui deepEqual
- * browser tests expect (all working)
- * browser version built
- * chai.fail (should ui)
- * expect tests browser compatible
- * tests for should and expect (all pass)
- * moved fail to primary export
- * should compatibility testing
- * within, greaterThan, object, keys,
- * Aliases
- * Assertion#property now correctly works with negate and undefined values
- * error message language matches should
- * Assertion#respondTo
- * Assertion now uses inspect util
- * git ignore node modules
- * should is exported
- * AssertionError __proto__ from Error.prototype
- * add should interface for should.js compatibility
- * moved eql to until folder and added inspect from (joyent/node)
- * added mocha for testing
- * browser build for current api
- * multiple .property assertions
- * added deep equal from node
-
-0.0.2 / 2011-12-07
-==================
-
- * cleaner output on error
- * improved exists detection
- * package remnant artifact
- * empty deep equal
- * test browser build
- * assertion cleanup
- * client compile script
- * makefile
- * most of the basic assertions
- * allow no parameters to assertion error
- * name change
- * assertion error instance
- * main exports: assert() & expect()
- * initialize
View
45 node_modules/chai/Makefile
@@ -1,45 +0,0 @@
-
-TESTS = test/*.js
-REPORTER = spec
-SRC = $(shell find lib -name "*.js" -type f)
-
-all: chai.js
-
-chai.js: $(SRC)
- @node support/compile $^
-
-clean:
- @rm -f chai.js
-
-docs: clean-docs
- @./node_modules/.bin/codex build \
- -i docs
- @cp chai.js docs/out/chai.js
- @mkdir -p docs/out/support/tests
- @mkdir docs/out/support/coverage
- @cp node_modules/mocha/mocha.js docs/out/support/tests
- @cp node_modules/mocha/mocha.css docs/out/support/tests
- @cp -R test/*.js docs/out/support/tests
- @cp test/browser/docs.html docs/out/support/tests/index.html
- @make test-cov
- @cp coverage.html docs/out/support/coverage/index.html
- @./node_modules/.bin/codex serve \
- -d docs/out
-
-clean-docs:
- @rm -rf docs/out
-
-test:
- @NODE_ENV=test ./node_modules/.bin/mocha \
- --reporter $(REPORTER) \
- --ui tdd \
- $(TESTS)
-
-test-cov: lib-cov
- @CHAI_COV=1 $(MAKE) test REPORTER=html-cov > coverage.html
-
-lib-cov:
- @rm -rf lib-cov
- @jscoverage lib lib-cov
-
-.PHONY: clean test docs clean-docs test-cov lib-cov
View
97 node_modules/chai/README.md
@@ -1,97 +0,0 @@
-[![Build Status](https://secure.travis-ci.org/logicalparadox/chai.png)](http://travis-ci.org/logicalparadox/chai)
-
-[![Chai Documentation](https://github.com/logicalparadox/chai/raw/master/docs/template/assets/img/chai-logo.png)](http://chaijs.com)
-
-Chai is a BDD / TDD assertion library for [node](http://nodejs.org) and the browser that
-can be delightfully paired with any javascript testing framework.
-
-For more information view the [documentation](http://chaijs.com).
-
-## Installation
-
-Chai is available for both node.js and the browser using any
-test framework you like.
-
-### Node.js
-
-Package is available through [npm](http://npmjs.org):
-
- npm install chai
-
-Recommend adding it to package.json devDependancies.
-
-### Browser
-
-Include the chai browser build in your testing suite.
-
- <script src="chai.js" type="text/javascript"></script>
-
-Currently supports all modern browsers: IE 9+, Chrome 7+, FireFox 4+, Safari 5+. Want to know if your browser is compatible?
-Run the [online test suite](http://chaijs.com/support/tests/).
-
-## Plugins
-
-The Chai community is growing! Plugins allow developers to expand Chai's available
-assertions. Here is what the community has come up with so far:
-
-* [chai-spies](https://github.com/logicalparadox/chai-spies) is a basic spy implementation for chai. It's also
-a good resource for building chai plugins that work in both node.js and the browser.
-* [chai-jquery](https://github.com/jfirebaugh/chai-jquery) by [@jfirebaugh](https://github.com/jfirebaugh)
-provides deep jQuery integration with chai's `should` and `expect`.
-* [jack](https://github.com/vesln/jack) by [@vesln](https://github.com/vesln) is a mock/stub library that
-can be used as a stand-alone or with chai.
-* [sinon-chai](https://github.com/domenic/sinon-chai) by [@domenic](https://github.com/domenic) extends chai with
-assertions for the Sinon.js mocking framework.
-
-## Getting Help
-
-If you have questions or issues, please use this projects
-[Github Issues](https://github.com/logicalparadox/chai/issues). You can also keep up to date
-on the [Google Group](http://groups.google.com/group/chaijs) or ping [@jakeluer](http://twitter.com/jakeluer)
-directly on Twitter. Chai developers can also be found on Freenode IRC in #letstest.js.
-
-## Versions
-
-The current stable version tree is the `0.5.x` tree on the `master` branch. If you are interested in seeing
-what we have planned, or if you are a plugin developer interested in preparing your plugins for the
-next major release, see the `0.6.x` branch.
-
-- Stable: 0.5.x
-- Unstables: 0.6.x
-
-## Contributors
-
- commits: 252
- files : 71
- authors:
- 192 Jake Luer 76.2%
- 53 Veselin Todorov 21.0%
- 3 Jeff Barczewski 1.2%
- 1 Vinay Pulim 0.4%
- 1 Jo Liss 0.4%
- 1 Domenic Denicola 0.4%
- 1 John Firebaugh 0.4%
-
-## License
-
-(The MIT License)
-
-Copyright (c) 2011-2012 Jake Luer <jake@alogicalparadox.com>
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
View
2,223 node_modules/chai/chai.js
0 additions, 2,223 deletions not shown because the diff is too large. Please use a local Git client to view these changes.
View
333 node_modules/chai/coverage.html
0 additions, 333 deletions not shown because the diff is too large. Please use a local Git client to view these changes.
View
3 node_modules/chai/index.js
@@ -1,3 +0,0 @@
-module.exports = (process && process.env && process.env.CHAI_COV)
- ? require('./lib-cov/chai')
- : require('./lib/chai');
View
581 node_modules/chai/lib-cov/assertion.js
@@ -1,581 +0,0 @@
-/* automatically generated by JSCoverage - do not edit */
-if (typeof _$jscoverage === 'undefined') _$jscoverage = {};
-if (! _$jscoverage['assertion.js']) {
- _$jscoverage['assertion.js'] = [];
- _$jscoverage['assertion.js'][48] = 0;
- _$jscoverage['assertion.js'][57] = 0;
- _$jscoverage['assertion.js'][68] = 0;
- _$jscoverage['assertion.js'][69] = 0;
- _$jscoverage['assertion.js'][70] = 0;
- _$jscoverage['assertion.js'][71] = 0;
- _$jscoverage['assertion.js'][87] = 0;
- _$jscoverage['assertion.js'][103] = 0;
- _$jscoverage['assertion.js'][104] = 0;
- _$jscoverage['assertion.js'][105] = 0;
- _$jscoverage['assertion.js'][108] = 0;
- _$jscoverage['assertion.js'][109] = 0;
- _$jscoverage['assertion.js'][127] = 0;
- _$jscoverage['assertion.js'][129] = 0;
- _$jscoverage['assertion.js'][143] = 0;
- _$jscoverage['assertion.js'][145] = 0;
- _$jscoverage['assertion.js'][159] = 0;
- _$jscoverage['assertion.js'][161] = 0;
- _$jscoverage['assertion.js'][176] = 0;
- _$jscoverage['assertion.js'][178] = 0;
- _$jscoverage['assertion.js'][179] = 0;
- _$jscoverage['assertion.js'][193] = 0;
- _$jscoverage['assertion.js'][195] = 0;
- _$jscoverage['assertion.js'][208] = 0;
- _$jscoverage['assertion.js'][210] = 0;
- _$jscoverage['assertion.js'][224] = 0;
- _$jscoverage['assertion.js'][226] = 0;
- _$jscoverage['assertion.js'][240] = 0;
- _$jscoverage['assertion.js'][242] = 0;
- _$jscoverage['assertion.js'][256] = 0;
- _$jscoverage['assertion.js'][258] = 0;
- _$jscoverage['assertion.js'][272] = 0;
- _$jscoverage['assertion.js'][274] = 0;
- _$jscoverage['assertion.js'][275] = 0;
- _$jscoverage['assertion.js'][294] = 0;
- _$jscoverage['assertion.js'][296] = 0;
- _$jscoverage['assertion.js'][301] = 0;
- _$jscoverage['assertion.js'][315] = 0;
- _$jscoverage['assertion.js'][317] = 0;
- _$jscoverage['assertion.js'][324] = 0;
- _$jscoverage['assertion.js'][338] = 0;
- _$jscoverage['assertion.js'][340] = 0;
- _$jscoverage['assertion.js'][347] = 0;
- _$jscoverage['assertion.js'][366] = 0;
- _$jscoverage['assertion.js'][368] = 0;
- _$jscoverage['assertion.js'][374] = 0;
- _$jscoverage['assertion.js'][390] = 0;
- _$jscoverage['assertion.js'][392] = 0;
- _$jscoverage['assertion.js'][394] = 0;
- _$jscoverage['assertion.js'][395] = 0;
- _$jscoverage['assertion.js'][396] = 0;
- _$jscoverage['assertion.js'][397] = 0;
- _$jscoverage['assertion.js'][400] = 0;
- _$jscoverage['assertion.js'][405] = 0;
- _$jscoverage['assertion.js'][423] = 0;
- _$jscoverage['assertion.js'][425] = 0;
- _$jscoverage['assertion.js'][433] = 0;
- _$jscoverage['assertion.js'][450] = 0;
- _$jscoverage['assertion.js'][451] = 0;
- _$jscoverage['assertion.js'][457] = 0;
- _$jscoverage['assertion.js'][472] = 0;
- _$jscoverage['assertion.js'][473] = 0;
- _$jscoverage['assertion.js'][479] = 0;
- _$jscoverage['assertion.js'][494] = 0;
- _$jscoverage['assertion.js'][495] = 0;
- _$jscoverage['assertion.js'][500] = 0;
- _$jscoverage['assertion.js'][515] = 0;
- _$jscoverage['assertion.js'][516] = 0;
- _$jscoverage['assertion.js'][521] = 0;
- _$jscoverage['assertion.js'][537] = 0;
- _$jscoverage['assertion.js'][538] = 0;
- _$jscoverage['assertion.js'][540] = 0;
- _$jscoverage['assertion.js'][545] = 0;
- _$jscoverage['assertion.js'][560] = 0;
- _$jscoverage['assertion.js'][561] = 0;
- _$jscoverage['assertion.js'][563] = 0;
- _$jscoverage['assertion.js'][571] = 0;
- _$jscoverage['assertion.js'][590] = 0;
- _$jscoverage['assertion.js'][591] = 0;
- _$jscoverage['assertion.js'][592] = 0;
- _$jscoverage['assertion.js'][597] = 0;
- _$jscoverage['assertion.js'][617] = 0;
- _$jscoverage['assertion.js'][618] = 0;
- _$jscoverage['assertion.js'][619] = 0;
- _$jscoverage['assertion.js'][620] = 0;
- _$jscoverage['assertion.js'][623] = 0;
- _$jscoverage['assertion.js'][629] = 0;
- _$jscoverage['assertion.js'][630] = 0;
- _$jscoverage['assertion.js'][640] = 0;
- _$jscoverage['assertion.js'][641] = 0;
- _$jscoverage['assertion.js'][657] = 0;
- _$jscoverage['assertion.js'][658] = 0;
- _$jscoverage['assertion.js'][662] = 0;
- _$jscoverage['assertion.js'][679] = 0;
- _$jscoverage['assertion.js'][680] = 0;
- _$jscoverage['assertion.js'][681] = 0;
- _$jscoverage['assertion.js'][683] = 0;
- _$jscoverage['assertion.js'][691] = 0;
- _$jscoverage['assertion.js'][706] = 0;
- _$jscoverage['assertion.js'][707] = 0;
- _$jscoverage['assertion.js'][712] = 0;
- _$jscoverage['assertion.js'][727] = 0;
- _$jscoverage['assertion.js'][728] = 0;
- _$jscoverage['assertion.js'][733] = 0;
- _$jscoverage['assertion.js'][748] = 0;
- _$jscoverage['assertion.js'][749] = 0;
- _$jscoverage['assertion.js'][751] = 0;
- _$jscoverage['assertion.js'][756] = 0;
- _$jscoverage['assertion.js'][770] = 0;
- _$jscoverage['assertion.js'][772] = 0;
- _$jscoverage['assertion.js'][773] = 0;
- _$jscoverage['assertion.js'][792] = 0;
- _$jscoverage['assertion.js'][793] = 0;
- _$jscoverage['assertion.js'][796] = 0;
- _$jscoverage['assertion.js'][800] = 0;
- _$jscoverage['assertion.js'][802] = 0;
- _$jscoverage['assertion.js'][806] = 0;
- _$jscoverage['assertion.js'][807] = 0;
- _$jscoverage['assertion.js'][811] = 0;
- _$jscoverage['assertion.js'][812] = 0;
- _$jscoverage['assertion.js'][816] = 0;
- _$jscoverage['assertion.js'][817] = 0;
- _$jscoverage['assertion.js'][818] = 0;
- _$jscoverage['assertion.js'][820] = 0;
- _$jscoverage['assertion.js'][821] = 0;
- _$jscoverage['assertion.js'][823] = 0;
- _$jscoverage['assertion.js'][827] = 0;
- _$jscoverage['assertion.js'][830] = 0;
- _$jscoverage['assertion.js'][833] = 0;
- _$jscoverage['assertion.js'][841] = 0;
- _$jscoverage['assertion.js'][871] = 0;
- _$jscoverage['assertion.js'][872] = 0;
- _$jscoverage['assertion.js'][874] = 0;
- _$jscoverage['assertion.js'][876] = 0;
- _$jscoverage['assertion.js'][877] = 0;
- _$jscoverage['assertion.js'][878] = 0;
- _$jscoverage['assertion.js'][879] = 0;
- _$jscoverage['assertion.js'][880] = 0;
- _$jscoverage['assertion.js'][881] = 0;
- _$jscoverage['assertion.js'][884] = 0;
- _$jscoverage['assertion.js'][885] = 0;
- _$jscoverage['assertion.js'][888] = 0;
- _$jscoverage['assertion.js'][889] = 0;
- _$jscoverage['assertion.js'][893] = 0;
- _$jscoverage['assertion.js'][896] = 0;
- _$jscoverage['assertion.js'][897] = 0;
- _$jscoverage['assertion.js'][902] = 0;
- _$jscoverage['assertion.js'][903] = 0;
- _$jscoverage['assertion.js'][904] = 0;
- _$jscoverage['assertion.js'][909] = 0;
- _$jscoverage['assertion.js'][911] = 0;
- _$jscoverage['assertion.js'][915] = 0;
- _$jscoverage['assertion.js'][917] = 0;
- _$jscoverage['assertion.js'][922] = 0;
- _$jscoverage['assertion.js'][938] = 0;
- _$jscoverage['assertion.js'][939] = 0;
- _$jscoverage['assertion.js'][943] = 0;
- _$jscoverage['assertion.js'][951] = 0;
- _$jscoverage['assertion.js'][966] = 0;
- _$jscoverage['assertion.js'][967] = 0;
- _$jscoverage['assertion.js'][975] = 0;
- _$jscoverage['assertion.js'][991] = 0;
- _$jscoverage['assertion.js'][992] = 0;
- _$jscoverage['assertion.js'][997] = 0;
- _$jscoverage['assertion.js'][1004] = 0;
- _$jscoverage['assertion.js'][1005] = 0;
- _$jscoverage['assertion.js'][1006] = 0;
-}
-_$jscoverage['assertion.js'][48]++;
-var AssertionError = require("./error"), eql = require("./utils/eql"), toString = Object.prototype.toString, inspect = require("./utils/inspect");
-_$jscoverage['assertion.js'][57]++;
-module.exports = Assertion;
-_$jscoverage['assertion.js'][68]++;
-function Assertion(obj, msg, stack) {
- _$jscoverage['assertion.js'][69]++;
- this.ssfi = stack || arguments.callee;
- _$jscoverage['assertion.js'][70]++;
- this.obj = obj;
- _$jscoverage['assertion.js'][71]++;
- this.msg = msg;
-}
-_$jscoverage['assertion.js'][87]++;
-Assertion.includeStack = false;
-_$jscoverage['assertion.js'][103]++;
-Assertion.prototype.assert = (function (expr, msg, negateMsg, expected, actual) {
- _$jscoverage['assertion.js'][104]++;
- actual = actual || this.obj;
- _$jscoverage['assertion.js'][105]++;
- var msg = (this.negate? negateMsg: msg), ok = this.negate? ! expr: expr;
- _$jscoverage['assertion.js'][108]++;
- if (! ok) {
- _$jscoverage['assertion.js'][109]++;
- throw new AssertionError({message: this.msg? this.msg + ": " + msg: msg, actual: actual, expected: expected, stackStartFunction: Assertion.includeStack? this.assert: this.ssfi});
- }
-});
-_$jscoverage['assertion.js'][127]++;
-Object.defineProperty(Assertion.prototype, "inspect", {get: (function () {
- _$jscoverage['assertion.js'][129]++;
- return inspect(this.obj);
-}), configurable: true});
-_$jscoverage['assertion.js'][143]++;
-Object.defineProperty(Assertion.prototype, "to", {get: (function () {
- _$jscoverage['assertion.js'][145]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][159]++;
-Object.defineProperty(Assertion.prototype, "be", {get: (function () {
- _$jscoverage['assertion.js'][161]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][176]++;
-Object.defineProperty(Assertion.prototype, "been", {get: (function () {
- _$jscoverage['assertion.js'][178]++;
- this.tense = "past";
- _$jscoverage['assertion.js'][179]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][193]++;
-Object.defineProperty(Assertion.prototype, "an", {get: (function () {
- _$jscoverage['assertion.js'][195]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][208]++;
-Object.defineProperty(Assertion.prototype, "is", {get: (function () {
- _$jscoverage['assertion.js'][210]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][224]++;
-Object.defineProperty(Assertion.prototype, "and", {get: (function () {
- _$jscoverage['assertion.js'][226]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][240]++;
-Object.defineProperty(Assertion.prototype, "have", {get: (function () {
- _$jscoverage['assertion.js'][242]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][256]++;
-Object.defineProperty(Assertion.prototype, "with", {get: (function () {
- _$jscoverage['assertion.js'][258]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][272]++;
-Object.defineProperty(Assertion.prototype, "not", {get: (function () {
- _$jscoverage['assertion.js'][274]++;
- this.negate = true;
- _$jscoverage['assertion.js'][275]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][294]++;
-Object.defineProperty(Assertion.prototype, "ok", {get: (function () {
- _$jscoverage['assertion.js'][296]++;
- this.assert(this.obj, "expected " + this.inspect + " to be truthy", "expected " + this.inspect + " to be falsy");
- _$jscoverage['assertion.js'][301]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][315]++;
-Object.defineProperty(Assertion.prototype, "true", {get: (function () {
- _$jscoverage['assertion.js'][317]++;
- this.assert(true === this.obj, "expected " + this.inspect + " to be true", "expected " + this.inspect + " to be false", this.negate? false: true);
- _$jscoverage['assertion.js'][324]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][338]++;
-Object.defineProperty(Assertion.prototype, "false", {get: (function () {
- _$jscoverage['assertion.js'][340]++;
- this.assert(false === this.obj, "expected " + this.inspect + " to be false", "expected " + this.inspect + " to be true", this.negate? true: false);
- _$jscoverage['assertion.js'][347]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][366]++;
-Object.defineProperty(Assertion.prototype, "exist", {get: (function () {
- _$jscoverage['assertion.js'][368]++;
- this.assert(null != this.obj, "expected " + this.inspect + " to exist", "expected " + this.inspect + " to not exist");
- _$jscoverage['assertion.js'][374]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][390]++;
-Object.defineProperty(Assertion.prototype, "empty", {get: (function () {
- _$jscoverage['assertion.js'][392]++;
- var expected = this.obj;
- _$jscoverage['assertion.js'][394]++;
- if (Array.isArray(this.obj)) {
- _$jscoverage['assertion.js'][395]++;
- expected = this.obj.length;
- }
- else {
- _$jscoverage['assertion.js'][396]++;
- if (typeof this.obj === "object") {
- _$jscoverage['assertion.js'][397]++;
- expected = Object.keys(this.obj).length;
- }
- }
- _$jscoverage['assertion.js'][400]++;
- this.assert(! expected, "expected " + this.inspect + " to be empty", "expected " + this.inspect + " not to be empty");
- _$jscoverage['assertion.js'][405]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][423]++;
-Object.defineProperty(Assertion.prototype, "arguments", {get: (function () {
- _$jscoverage['assertion.js'][425]++;
- this.assert("[object Arguments]" == Object.prototype.toString.call(this.obj), "expected " + this.inspect + " to be arguments", "expected " + this.inspect + " to not be arguments", "[object Arguments]", Object.prototype.toString.call(this.obj));
- _$jscoverage['assertion.js'][433]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][450]++;
-Assertion.prototype.equal = (function (val) {
- _$jscoverage['assertion.js'][451]++;
- this.assert(val === this.obj, "expected " + this.inspect + " to equal " + inspect(val), "expected " + this.inspect + " to not equal " + inspect(val), val);
- _$jscoverage['assertion.js'][457]++;
- return this;
-});
-_$jscoverage['assertion.js'][472]++;
-Assertion.prototype.eql = (function (obj) {
- _$jscoverage['assertion.js'][473]++;
- this.assert(eql(obj, this.obj), "expected " + this.inspect + " to equal " + inspect(obj), "expected " + this.inspect + " to not equal " + inspect(obj), obj);
- _$jscoverage['assertion.js'][479]++;
- return this;
-});
-_$jscoverage['assertion.js'][494]++;
-Assertion.prototype.above = (function (val) {
- _$jscoverage['assertion.js'][495]++;
- this.assert(this.obj > val, "expected " + this.inspect + " to be above " + val, "expected " + this.inspect + " to be below " + val);
- _$jscoverage['assertion.js'][500]++;
- return this;
-});
-_$jscoverage['assertion.js'][515]++;
-Assertion.prototype.below = (function (val) {
- _$jscoverage['assertion.js'][516]++;
- this.assert(this.obj < val, "expected " + this.inspect + " to be below " + val, "expected " + this.inspect + " to be above " + val);
- _$jscoverage['assertion.js'][521]++;
- return this;
-});
-_$jscoverage['assertion.js'][537]++;
-Assertion.prototype.within = (function (start, finish) {
- _$jscoverage['assertion.js'][538]++;
- var range = start + ".." + finish;
- _$jscoverage['assertion.js'][540]++;
- this.assert(this.obj >= start && this.obj <= finish, "expected " + this.inspect + " to be within " + range, "expected " + this.inspect + " to not be within " + range);
- _$jscoverage['assertion.js'][545]++;
- return this;
-});
-_$jscoverage['assertion.js'][560]++;
-Assertion.prototype.a = (function (type) {
- _$jscoverage['assertion.js'][561]++;
- var klass = type.charAt(0).toUpperCase() + type.slice(1);
- _$jscoverage['assertion.js'][563]++;
- this.assert("[object " + klass + "]" === toString.call(this.obj), "expected " + this.inspect + " to be a " + type, "expected " + this.inspect + " not to be a " + type, "[object " + klass + "]", toString.call(this.obj));
- _$jscoverage['assertion.js'][571]++;
- return this;
-});
-_$jscoverage['assertion.js'][590]++;
-Assertion.prototype["instanceof"] = (function (constructor) {
- _$jscoverage['assertion.js'][591]++;
- var name = constructor.name;
- _$jscoverage['assertion.js'][592]++;
- this.assert(this.obj instanceof constructor, "expected " + this.inspect + " to be an instance of " + name, "expected " + this.inspect + " to not be an instance of " + name);
- _$jscoverage['assertion.js'][597]++;
- return this;
-});
-_$jscoverage['assertion.js'][617]++;
-Assertion.prototype.property = (function (name, val) {
- _$jscoverage['assertion.js'][618]++;
- if (this.negate && undefined !== val) {
- _$jscoverage['assertion.js'][619]++;
- if (undefined === this.obj[name]) {
- _$jscoverage['assertion.js'][620]++;
- throw new Error(this.inspect + " has no property " + inspect(name));
- }
- }
- else {
- _$jscoverage['assertion.js'][623]++;
- this.assert(undefined !== this.obj[name], "expected " + this.inspect + " to have a property " + inspect(name), "expected " + this.inspect + " to not have property " + inspect(name));
- }
- _$jscoverage['assertion.js'][629]++;
- if (undefined !== val) {
- _$jscoverage['assertion.js'][630]++;
- this.assert(val === this.obj[name], "expected " + this.inspect + " to have a property " + inspect(name) + " of " + inspect(val) + ", but got " + inspect(this.obj[name]), "expected " + this.inspect + " to not have a property " + inspect(name) + " of " + inspect(val), val, this.obj[val]);
- }
- _$jscoverage['assertion.js'][640]++;
- this.obj = this.obj[name];
- _$jscoverage['assertion.js'][641]++;
- return this;
-});
-_$jscoverage['assertion.js'][657]++;
-Assertion.prototype.ownProperty = (function (name) {
- _$jscoverage['assertion.js'][658]++;
- this.assert(this.obj.hasOwnProperty(name), "expected " + this.inspect + " to have own property " + inspect(name), "expected " + this.inspect + " to not have own property " + inspect(name));
- _$jscoverage['assertion.js'][662]++;
- return this;
-});
-_$jscoverage['assertion.js'][679]++;
-Assertion.prototype.length = (function (n) {
- _$jscoverage['assertion.js'][680]++;
- new Assertion(this.obj).to.have.property("length");
- _$jscoverage['assertion.js'][681]++;
- var len = this.obj.length;
- _$jscoverage['assertion.js'][683]++;
- this.assert(len == n, "expected " + this.inspect + " to have a length of " + n + " but got " + len, "expected " + this.inspect + " to not have a length of " + len, n, len);
- _$jscoverage['assertion.js'][691]++;
- return this;
-});
-_$jscoverage['assertion.js'][706]++;
-Assertion.prototype.match = (function (re) {
- _$jscoverage['assertion.js'][707]++;
- this.assert(re.exec(this.obj), "expected " + this.inspect + " to match " + re, "expected " + this.inspect + " not to match " + re);
- _$jscoverage['assertion.js'][712]++;
- return this;
-});
-_$jscoverage['assertion.js'][727]++;
-Assertion.prototype.include = (function (obj) {
- _$jscoverage['assertion.js'][728]++;
- this.assert(~ this.obj.indexOf(obj), "expected " + this.inspect + " to include " + inspect(obj), "expected " + this.inspect + " to not include " + inspect(obj));
- _$jscoverage['assertion.js'][733]++;
- return this;
-});
-_$jscoverage['assertion.js'][748]++;
-Assertion.prototype.string = (function (str) {
- _$jscoverage['assertion.js'][749]++;
- new Assertion(this.obj).is.a("string");
- _$jscoverage['assertion.js'][751]++;
- this.assert(~ this.obj.indexOf(str), "expected " + this.inspect + " to contain " + inspect(str), "expected " + this.inspect + " to not contain " + inspect(str));
- _$jscoverage['assertion.js'][756]++;
- return this;
-});
-_$jscoverage['assertion.js'][770]++;
-Object.defineProperty(Assertion.prototype, "contain", {get: (function () {
- _$jscoverage['assertion.js'][772]++;
- this.contains = true;
- _$jscoverage['assertion.js'][773]++;
- return this;
-}), configurable: true});
-_$jscoverage['assertion.js'][792]++;
-Assertion.prototype.keys = (function (keys) {
- _$jscoverage['assertion.js'][793]++;
- var str, ok = true;
- _$jscoverage['assertion.js'][796]++;
- keys = keys instanceof Array? keys: Array.prototype.slice.call(arguments);
- _$jscoverage['assertion.js'][800]++;
- if (! keys.length) {
- _$jscoverage['assertion.js'][800]++;
- throw new Error("keys required");
- }
- _$jscoverage['assertion.js'][802]++;
- var actual = Object.keys(this.obj), len = keys.length;
- _$jscoverage['assertion.js'][806]++;
- ok = keys.every((function (key) {
- _$jscoverage['assertion.js'][807]++;
- return ~ actual.indexOf(key);
-}));
- _$jscoverage['assertion.js'][811]++;
- if (! this.negate && ! this.contains) {
- _$jscoverage['assertion.js'][812]++;
- ok = ok && keys.length == actual.length;
- }
- _$jscoverage['assertion.js'][816]++;
- if (len > 1) {
- _$jscoverage['assertion.js'][817]++;
- keys = keys.map((function (key) {
- _$jscoverage['assertion.js'][818]++;
- return inspect(key);
-}));
- _$jscoverage['assertion.js'][820]++;
- var last = keys.pop();
- _$jscoverage['assertion.js'][821]++;
- str = keys.join(", ") + ", and " + last;
- }
- else {
- _$jscoverage['assertion.js'][823]++;
- str = inspect(keys[0]);
- }
- _$jscoverage['assertion.js'][827]++;
- str = (len > 1? "keys ": "key ") + str;
- _$jscoverage['assertion.js'][830]++;
- str = (this.contains? "contain ": "have ") + str;
- _$jscoverage['assertion.js'][833]++;
- this.assert(ok, "expected " + this.inspect + " to " + str, "expected " + this.inspect + " to not " + str, keys, Object.keys(this.obj));
- _$jscoverage['assertion.js'][841]++;
- return this;
-});
-_$jscoverage['assertion.js'][871]++;
-Assertion.prototype["throw"] = (function (constructor, msg) {
- _$jscoverage['assertion.js'][872]++;
- new Assertion(this.obj).is.a("function");
- _$jscoverage['assertion.js'][874]++;
- var thrown = false;
- _$jscoverage['assertion.js'][876]++;
- if (arguments.length === 0) {
- _$jscoverage['assertion.js'][877]++;
- msg = null;
- _$jscoverage['assertion.js'][878]++;
- constructor = null;
- }
- else {
- _$jscoverage['assertion.js'][879]++;
- if (constructor && (constructor instanceof RegExp || "string" === typeof constructor)) {
- _$jscoverage['assertion.js'][880]++;
- msg = constructor;
- _$jscoverage['assertion.js'][881]++;
- constructor = null;
- }
- }
- _$jscoverage['assertion.js'][884]++;
- try {
- _$jscoverage['assertion.js'][885]++;
- this.obj();
- }
- catch (err) {
- _$jscoverage['assertion.js'][888]++;
- if (constructor && "function" === typeof constructor) {
- _$jscoverage['assertion.js'][889]++;
- this.assert(err instanceof constructor && err.name == constructor.name, "expected " + this.inspect + " to throw " + constructor.name + " but a " + err.name + " was thrown", "expected " + this.inspect + " to not throw " + constructor.name);
- _$jscoverage['assertion.js'][893]++;
- if (! msg) {
- _$jscoverage['assertion.js'][893]++;
- return this;
- }
- }
- _$jscoverage['assertion.js'][896]++;
- if (err.message && msg && msg instanceof RegExp) {
- _$jscoverage['assertion.js'][897]++;
- this.assert(msg.exec(err.message), "expected " + this.inspect + " to throw error matching " + msg + " but got " + inspect(err.message), "expected " + this.inspect + " to throw error not matching " + msg);
- _$jscoverage['assertion.js'][902]++;
- return this;
- }
- else {
- _$jscoverage['assertion.js'][903]++;
- if (err.message && msg && "string" === typeof msg) {
- _$jscoverage['assertion.js'][904]++;
- this.assert(~ err.message.indexOf(msg), "expected " + this.inspect + " to throw error including " + inspect(msg) + " but got " + inspect(err.message), "expected " + this.inspect + " to throw error not including " + inspect(msg));
- _$jscoverage['assertion.js'][909]++;
- return this;
- }
- else {
- _$jscoverage['assertion.js'][911]++;
- thrown = true;
- }
- }
- }
- _$jscoverage['assertion.js'][915]++;
- var name = (constructor? constructor.name: "an error");
- _$jscoverage['assertion.js'][917]++;
- this.assert(thrown === true, "expected " + this.inspect + " to throw " + name, "expected " + this.inspect + " to not throw " + name);
- _$jscoverage['assertion.js'][922]++;
- return this;
-});
-_$jscoverage['assertion.js'][938]++;
-Assertion.prototype.respondTo = (function (method) {
- _$jscoverage['assertion.js'][939]++;
- var context = ("function" === typeof this.obj)? this.obj.prototype[method]: this.obj[method];
- _$jscoverage['assertion.js'][943]++;
- this.assert("function" === typeof context, "expected " + this.inspect + " to respond to " + inspect(method), "expected " + this.inspect + " to not respond to " + inspect(method), "function", typeof context);
- _$jscoverage['assertion.js'][951]++;
- return this;
-});
-_$jscoverage['assertion.js'][966]++;
-Assertion.prototype.satisfy = (function (matcher) {
- _$jscoverage['assertion.js'][967]++;
- this.assert(matcher(this.obj), "expected " + this.inspect + " to satisfy " + inspect(matcher), "expected " + this.inspect + " to not satisfy" + inspect(matcher), this.negate? false: true, matcher(this.obj));
- _$jscoverage['assertion.js'][975]++;
- return this;
-});
-_$jscoverage['assertion.js'][991]++;
-Assertion.prototype.closeTo = (function (expected, delta) {
- _$jscoverage['assertion.js'][992]++;
- this.assert((this.obj - delta === expected) || (this.obj + delta === expected), "expected " + this.inspect + " to be close to " + expected + " +/- " + delta, "expected " + this.inspect + " not to be close to " + expected + " +/- " + delta);
- _$jscoverage['assertion.js'][997]++;
- return this;
-});
-_$jscoverage['assertion.js'][1004]++;
-(function alias(name, as) {
- _$jscoverage['assertion.js'][1005]++;
- Assertion.prototype[as] = Assertion.prototype[name];
- _$jscoverage['assertion.js'][1006]++;
- return alias;
-})("length", "lengthOf")("keys", "key")("ownProperty", "haveOwnProperty")("above", "greaterThan")("below", "lessThan")("throw", "throws")("throw", "Throw")("instanceof", "instanceOf");
-_$jscoverage['assertion.js'].source = ["/*!"," * chai"," * Copyright(c) 2011 Jake Luer &lt;jake@alogicalparadox.com&gt;"," * MIT Licensed"," *"," * Primarily a refactor of: should.js"," * https://github.com/visionmedia/should.js"," * Copyright(c) 2011 TJ Holowaychuk &lt;tj@vision-media.ca&gt;"," * MIT Licensed"," */","","/**"," * ### BDD Style Introduction"," *"," * The BDD style is exposed through `expect` or `should` interfaces. In both"," * scenarios, you chain together natural language assertions."," *"," * // expect"," * var expect = require('chai').expect;"," * expect(foo).to.equal('bar');"," *"," * // should"," * var should = require('chai').should();"," * foo.should.equal('bar');"," *"," * #### Differences"," *"," * The `expect` interface provides a function as a starting point for chaining"," * your language assertions. It works on node.js and in all browsers."," *"," * The `should` interface extends `Object.prototype` to provide a single getter as"," * the starting point for your language assertions. It works on node.js and in"," * all browsers except Internet Explorer."," *"," * #### Configuration"," *"," * By default, Chai does not show stack traces upon an AssertionError. This can"," * be changed by modifying the `includeStack` parameter for chai.Assertion. For example:"," *"," * var chai = require('chai');"," * chai.Assertion.includeStack = true; // defaults to false"," */","","/*!"," * Module dependencies."," */","","var AssertionError = require('./error')"," , eql = require('./utils/eql')"," , toString = Object.prototype.toString"," , inspect = require('./utils/inspect');","","/*!"," * Module export."," */","","module.exports = Assertion;","","","/*!"," * # Assertion Constructor"," *"," * Creates object for chaining."," *"," * @api private"," */","","function Assertion (obj, msg, stack) {"," this.ssfi = stack || arguments.callee;"," this.obj = obj;"," this.msg = msg;","}","","/*!"," * ## Assertion.includeStack"," * , toString = Object.prototype.toString"," *"," * User configurable property, influences whether stack trace"," * is included in Assertion error message. Default of false"," * suppresses stack trace in the error message"," *"," * Assertion.includeStack = true; // enable stack on error"," *"," * @api public"," */","","Assertion.includeStack = false;","","/*!"," * # .assert(expression, message, negateMessage, expected, actual)"," *"," * Executes an expression and check expectations. Throws AssertionError for reporting if test doesn't pass."," *"," * @name assert"," * @param {Philosophical} expression to be tested"," * @param {String} message to display if fails"," * @param {String} negatedMessage to display if negated expression fails"," * @param {*} expected value (remember to check for negation)"," * @param {*} actual (optional) will default to `this.obj`"," * @api private"," */","","Assertion.prototype.assert = function (expr, msg, negateMsg, expected, actual) {"," actual = actual || this.obj;"," var msg = (this.negate ? negateMsg : msg)"," , ok = this.negate ? !expr : expr;",""," if (!ok) {"," throw new AssertionError({"," message: this.msg ? this.msg + ': ' + msg : msg // include custom message if available"," , actual: actual"," , expected: expected"," , stackStartFunction: (Assertion.includeStack) ? this.assert : this.ssfi"," });"," }","};","","/*!"," * # inspect"," *"," * Returns the current object stringified."," *"," * @name inspect"," * @api private"," */","","Object.defineProperty(Assertion.prototype, 'inspect',"," { get: function () {"," return inspect(this.obj);"," }"," , configurable: true","});","","/**"," * # to"," *"," * Language chain."," *"," * @name to"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'to',"," { get: function () {"," return this;"," }"," , configurable: true","});","","/**"," * # be"," *"," * Language chain."," *"," * @name be"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'be',"," { get: function () {"," return this;"," }"," , configurable: true","});","","/**"," * # been"," *"," * Language chain. Also tests `tense` to past for addon"," * modules that use the tense feature."," *"," * @name been"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'been',"," { get: function () {"," this.tense = 'past';"," return this;"," }"," , configurable: true","});","","/**"," * # an"," *"," * Language chain."," *"," * @name an"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'an',"," { get: function () {"," return this;"," }"," , configurable: true","});","/**"," * # is"," *"," * Language chain."," *"," * @name is"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'is',"," { get: function () {"," return this;"," }"," , configurable: true","});","","/**"," * # and"," *"," * Language chain."," *"," * @name and"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'and',"," { get: function () {"," return this;"," }"," , configurable: true","});","","/**"," * # have"," *"," * Language chain."," *"," * @name have"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'have',"," { get: function () {"," return this;"," }"," , configurable: true","});","","/**"," * # with"," *"," * Language chain."," *"," * @name with"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'with',"," { get: function () {"," return this;"," }"," , configurable: true","});","","/**"," * # .not"," *"," * Negates any of assertions following in the chain."," *"," * @name not"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'not',"," { get: function () {"," this.negate = true;"," return this;"," }"," , configurable: true","});","","/**"," * # .ok"," *"," * Assert object truthiness."," *"," * expect('everthing').to.be.ok;"," * expect(false).to.not.be.ok;"," * expect(undefined).to.not.be.ok;"," * expect(null).to.not.be.ok;"," *"," * @name ok"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'ok',"," { get: function () {"," this.assert("," this.obj"," , 'expected ' + this.inspect + ' to be truthy'"," , 'expected ' + this.inspect + ' to be falsy');",""," return this;"," }"," , configurable: true","});","","/**"," * # .true"," *"," * Assert object is true"," *"," * @name true"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'true',"," { get: function () {"," this.assert("," true === this.obj"," , 'expected ' + this.inspect + ' to be true'"," , 'expected ' + this.inspect + ' to be false'"," , this.negate ? false : true"," );",""," return this;"," }"," , configurable: true","});","","/**"," * # .false"," *"," * Assert object is false"," *"," * @name false"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'false',"," { get: function () {"," this.assert("," false === this.obj"," , 'expected ' + this.inspect + ' to be false'"," , 'expected ' + this.inspect + ' to be true'"," , this.negate ? true : false"," );",""," return this;"," }"," , configurable: true","});","","/**"," * # .exist"," *"," * Assert object exists (null)."," *"," * var foo = 'hi'"," * , bar;"," * expect(foo).to.exist;"," * expect(bar).to.not.exist;"," *"," * @name exist"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'exist',"," { get: function () {"," this.assert("," null != this.obj"," , 'expected ' + this.inspect + ' to exist'"," , 'expected ' + this.inspect + ' to not exist'"," );",""," return this;"," }"," , configurable: true","});","","/**"," * # .empty"," *"," * Assert object's length to be 0."," *"," * expect([]).to.be.empty;"," *"," * @name empty"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'empty',"," { get: function () {"," var expected = this.obj;",""," if (Array.isArray(this.obj)) {"," expected = this.obj.length;"," } else if (typeof this.obj === 'object') {"," expected = Object.keys(this.obj).length;"," }",""," this.assert("," !expected"," , 'expected ' + this.inspect + ' to be empty'"," , 'expected ' + this.inspect + ' not to be empty');",""," return this;"," }"," , configurable: true","});","","/**"," * # .arguments"," *"," * Assert object is an instanceof arguments."," *"," * function test () {"," * expect(arguments).to.be.arguments;"," * }"," *"," * @name arguments"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'arguments',"," { get: function () {"," this.assert("," '[object Arguments]' == Object.prototype.toString.call(this.obj)"," , 'expected ' + this.inspect + ' to be arguments'"," , 'expected ' + this.inspect + ' to not be arguments'"," , '[object Arguments]'"," , Object.prototype.toString.call(this.obj)"," );",""," return this;"," }"," , configurable: true","});","","/**"," * # .equal(value)"," *"," * Assert strict equality."," *"," * expect('hello').to.equal('hello');"," *"," * @name equal"," * @param {*} value"," * @api public"," */","","Assertion.prototype.equal = function (val) {"," this.assert("," val === this.obj"," , 'expected ' + this.inspect + ' to equal ' + inspect(val)"," , 'expected ' + this.inspect + ' to not equal ' + inspect(val)"," , val );",""," return this;","};","","/**"," * # .eql(value)"," *"," * Assert deep equality."," *"," * expect({ foo: 'bar' }).to.eql({ foo: 'bar' });"," *"," * @name eql"," * @param {*} value"," * @api public"," */","","Assertion.prototype.eql = function (obj) {"," this.assert("," eql(obj, this.obj)"," , 'expected ' + this.inspect + ' to equal ' + inspect(obj)"," , 'expected ' + this.inspect + ' to not equal ' + inspect(obj)"," , obj );",""," return this;","};","","/**"," * # .above(value)"," *"," * Assert greater than `value`."," *"," * expect(10).to.be.above(5);"," *"," * @name above"," * @param {Number} value"," * @api public"," */","","Assertion.prototype.above = function (val) {"," this.assert("," this.obj &gt; val"," , 'expected ' + this.inspect + ' to be above ' + val"," , 'expected ' + this.inspect + ' to be below ' + val);",""," return this;","};","","/**"," * # .below(value)"," *"," * Assert less than `value`."," *"," * expect(5).to.be.below(10);"," *"," * @name below"," * @param {Number} value"," * @api public"," */","","Assertion.prototype.below = function (val) {"," this.assert("," this.obj &lt; val"," , 'expected ' + this.inspect + ' to be below ' + val"," , 'expected ' + this.inspect + ' to be above ' + val);",""," return this;","};","","/**"," * # .within(start, finish)"," *"," * Assert that a number is within a range."," *"," * expect(7).to.be.within(5,10);"," *"," * @name within"," * @param {Number} start lowerbound inclusive"," * @param {Number} finish upperbound inclusive"," * @api public"," */","","Assertion.prototype.within = function (start, finish) {"," var range = start + '..' + finish;",""," this.assert("," this.obj &gt;= start &amp;&amp; this.obj &lt;= finish"," , 'expected ' + this.inspect + ' to be within ' + range"," , 'expected ' + this.inspect + ' to not be within ' + range);",""," return this;","};","","/**"," * # .a(type)"," *"," * Assert typeof."," *"," * expect('test').to.be.a('string');"," *"," * @name a"," * @param {String} type"," * @api public"," */","","Assertion.prototype.a = function (type) {"," var klass = type.charAt(0).toUpperCase() + type.slice(1);",""," this.assert("," '[object ' + klass + ']' === toString.call(this.obj)"," , 'expected ' + this.inspect + ' to be a ' + type"," , 'expected ' + this.inspect + ' not to be a ' + type"," , '[object ' + klass + ']'"," , toString.call(this.obj)"," );",""," return this;","};","","/**"," * # .instanceof(constructor)"," *"," * Assert instanceof."," *"," * var Tea = function (name) { this.name = name; }"," * , Chai = new Tea('chai');"," *"," * expect(Chai).to.be.an.instanceOf(Tea);"," *"," * @name instanceof"," * @param {Constructor}"," * @alias instanceOf"," * @api public"," */","","Assertion.prototype.instanceof = function (constructor) {"," var name = constructor.name;"," this.assert("," this.obj instanceof constructor"," , 'expected ' + this.inspect + ' to be an instance of ' + name"," , 'expected ' + this.inspect + ' to not be an instance of ' + name);",""," return this;","};","","/**"," * # .property(name, [value])"," *"," * Assert that property of `name` exists, optionally with `value`."," *"," * var obj = { foo: 'bar' }"," * expect(obj).to.have.property('foo');"," * expect(obj).to.have.property('foo', 'bar');"," * expect(obj).to.have.property('foo').to.be.a('string');"," *"," * @name property"," * @param {String} name"," * @param {*} value (optional)"," * @returns value of property for chaining"," * @api public"," */","","Assertion.prototype.property = function (name, val) {"," if (this.negate &amp;&amp; undefined !== val) {"," if (undefined === this.obj[name]) {"," throw new Error(this.inspect + ' has no property ' + inspect(name));"," }"," } else {"," this.assert("," undefined !== this.obj[name]"," , 'expected ' + this.inspect + ' to have a property ' + inspect(name)"," , 'expected ' + this.inspect + ' to not have property ' + inspect(name));"," }",""," if (undefined !== val) {"," this.assert("," val === this.obj[name]"," , 'expected ' + this.inspect + ' to have a property ' + inspect(name) + ' of ' +"," inspect(val) + ', but got ' + inspect(this.obj[name])"," , 'expected ' + this.inspect + ' to not have a property ' + inspect(name) + ' of ' + inspect(val)"," , val"," , this.obj[val]"," );"," }",""," this.obj = this.obj[name];"," return this;","};","","/**"," * # .ownProperty(name)"," *"," * Assert that has own property by `name`."," *"," * expect('test').to.have.ownProperty('length');"," *"," * @name ownProperty"," * @alias haveOwnProperty"," * @param {String} name"," * @api public"," */","","Assertion.prototype.ownProperty = function (name) {"," this.assert("," this.obj.hasOwnProperty(name)"," , 'expected ' + this.inspect + ' to have own property ' + inspect(name)"," , 'expected ' + this.inspect + ' to not have own property ' + inspect(name));"," return this;","};","","/**"," * # .length(val)"," *"," * Assert that object has expected length."," *"," * expect([1,2,3]).to.have.length(3);"," * expect('foobar').to.have.length(6);"," *"," * @name length"," * @alias lengthOf"," * @param {Number} length"," * @api public"," */","","Assertion.prototype.length = function (n) {"," new Assertion(this.obj).to.have.property('length');"," var len = this.obj.length;",""," this.assert("," len == n"," , 'expected ' + this.inspect + ' to have a length of ' + n + ' but got ' + len"," , 'expected ' + this.inspect + ' to not have a length of ' + len"," , n"," , len"," );",""," return this;","};","","/**"," * # .match(regexp)"," *"," * Assert that matches regular expression."," *"," * expect('foobar').to.match(/^foo/);"," *"," * @name match"," * @param {RegExp} RegularExpression"," * @api public"," */","","Assertion.prototype.match = function (re) {"," this.assert("," re.exec(this.obj)"," , 'expected ' + this.inspect + ' to match ' + re"," , 'expected ' + this.inspect + ' not to match ' + re);",""," return this;","};","","/**"," * # .include(obj)"," *"," * Assert the inclusion of an object in an Array or substring in string."," *"," * expect([1,2,3]).to.include(2);"," *"," * @name include"," * @param {Object|String|Number} obj"," * @api public"," */","","Assertion.prototype.include = function (obj) {"," this.assert("," ~this.obj.indexOf(obj)"," , 'expected ' + this.inspect + ' to include ' + inspect(obj)"," , 'expected ' + this.inspect + ' to not include ' + inspect(obj));",""," return this;","};","","/**"," * # .string(string)"," *"," * Assert inclusion of string in string."," *"," * expect('foobar').to.have.string('bar');"," *"," * @name string"," * @param {String} string"," * @api public"," */","","Assertion.prototype.string = function (str) {"," new Assertion(this.obj).is.a('string');",""," this.assert("," ~this.obj.indexOf(str)"," , 'expected ' + this.inspect + ' to contain ' + inspect(str)"," , 'expected ' + this.inspect + ' to not contain ' + inspect(str));",""," return this;","};","","","","/**"," * # contain"," *"," * Toggles the `contain` flag for the `keys` assertion."," *"," * @name contain"," * @api public"," */","","Object.defineProperty(Assertion.prototype, 'contain',"," { get: function () {"," this.contains = true;"," return this;"," },"," configurable: true","});","","/**"," * # .keys(key1, [key2], [...])"," *"," * Assert exact keys or the inclusing of keys using the `contain` modifier."," *"," * expect({ foo: 1, bar: 2 }).to.have.keys(['foo', 'bar']);"," * expect({ foo: 1, bar: 2, baz: 3 }).to.contain.keys('foo', 'bar');"," *"," * @name keys"," * @alias key"," * @param {String|Array} Keys"," * @api public"," */","","Assertion.prototype.keys = function(keys) {"," var str"," , ok = true;",""," keys = keys instanceof Array"," ? keys"," : Array.prototype.slice.call(arguments);",""," if (!keys.length) throw new Error('keys required');",""," var actual = Object.keys(this.obj)"," , len = keys.length;",""," // Inclusion"," ok = keys.every(function(key){"," return ~actual.indexOf(key);"," });",""," // Strict"," if (!this.negate &amp;&amp; !this.contains) {"," ok = ok &amp;&amp; keys.length == actual.length;"," }",""," // Key string"," if (len &gt; 1) {"," keys = keys.map(function(key){"," return inspect(key);"," });"," var last = keys.pop();"," str = keys.join(', ') + ', and ' + last;"," } else {"," str = inspect(keys[0]);"," }",""," // Form"," str = (len &gt; 1 ? 'keys ' : 'key ') + str;",""," // Have / include"," str = (this.contains ? 'contain ' : 'have ') + str;",""," // Assertion"," this.assert("," ok"," , 'expected ' + this.inspect + ' to ' + str"," , 'expected ' + this.inspect + ' to not ' + str"," , keys"," , Object.keys(this.obj)"," );",""," return this;","}","","/**"," * # .throw(constructor)"," *"," * Assert that a function will throw a specific type of error or that error"," * thrown will match a RegExp or include a string."," *"," * var fn = function () { throw new ReferenceError('This is a bad function.'); }"," * expect(fn).to.throw(ReferenceError);"," * expect(fn).to.throw(/bad function/);"," * expect(fn).to.not.throw('good function');"," * expect(fn).to.throw(ReferenceError, /bad function/);"," *"," * Please note that when a throw expectation is negated, it will check each"," * parameter independently, starting with Error constructor type. The appropriate way"," * to check for the existence of a type of error but for a message that does not match"," * is to use `and`."," *"," * expect(fn).to.throw(ReferenceError).and.not.throw(/good function/);"," *"," * @name throw"," * @alias throws"," * @alias Throw"," * @param {ErrorConstructor} constructor"," * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Error#Error_types"," * @api public"," */","","Assertion.prototype.throw = function (constructor, msg) {"," new Assertion(this.obj).is.a('function');",""," var thrown = false;",""," if (arguments.length === 0) {"," msg = null;"," constructor = null;"," } else if (constructor &amp;&amp; (constructor instanceof RegExp || 'string' === typeof constructor)) {"," msg = constructor;"," constructor = null;"," }",""," try {"," this.obj();"," } catch (err) {"," // first, check constructor"," if (constructor &amp;&amp; 'function' === typeof constructor) {"," this.assert("," err instanceof constructor &amp;&amp; err.name == constructor.name"," , 'expected ' + this.inspect + ' to throw ' + constructor.name + ' but a ' + err.name + ' was thrown'"," , 'expected ' + this.inspect + ' to not throw ' + constructor.name );"," if (!msg) return this;"," }"," // next, check message"," if (err.message &amp;&amp; msg &amp;&amp; msg instanceof RegExp) {"," this.assert("," msg.exec(err.message)"," , 'expected ' + this.inspect + ' to throw error matching ' + msg + ' but got ' + inspect(err.message)"," , 'expected ' + this.inspect + ' to throw error not matching ' + msg"," );"," return this;"," } else if (err.message &amp;&amp; msg &amp;&amp; 'string' === typeof msg) {"," this.assert("," ~err.message.indexOf(msg)"," , 'expected ' + this.inspect + ' to throw error including ' + inspect(msg) + ' but got ' + inspect(err.message)"," , 'expected ' + this.inspect + ' to throw error not including ' + inspect(msg)"," );"," return this;"," } else {"," thrown = true;"," }"," }",""," var name = (constructor ? constructor.name : 'an error');",""," this.assert("," thrown === true"," , 'expected ' + this.inspect + ' to throw ' + name"," , 'expected ' + this.inspect + ' to not throw ' + name);",""," return this;","};","","/**"," * # .respondTo(method)"," *"," * Assert that object/class will respond to a method."," *"," * expect(Klass).to.respondTo('bar');"," * expect(obj).to.respondTo('bar');"," *"," * @name respondTo"," * @param {String} method"," * @api public"," */","","Assertion.prototype.respondTo = function (method) {"," var context = ('function' === typeof this.obj)"," ? this.obj.prototype[method]"," : this.obj[method];",""," this.assert("," 'function' === typeof context"," , 'expected ' + this.inspect + ' to respond to ' + inspect(method)"," , 'expected ' + this.inspect + ' to not respond to ' + inspect(method)"," , 'function'"," , typeof context"," );",""," return this;","};","","/**"," * # .satisfy(method)"," *"," * Assert that passes a truth test."," *"," * expect(1).to.satisfy(function(num) { return num &gt; 0; });"," *"," * @name satisfy"," * @param {Function} matcher"," * @api public"," */","","Assertion.prototype.satisfy = function (matcher) {"," this.assert("," matcher(this.obj)"," , 'expected ' + this.inspect + ' to satisfy ' + inspect(matcher)"," , 'expected ' + this.inspect + ' to not satisfy' + inspect(matcher)"," , this.negate ? false : true"," , matcher(this.obj)"," );",""," return this;","};","","/**"," * # .closeTo(expected, delta)"," *"," * Assert that actual is equal to +/- delta."," *"," * expect(1.5).to.be.closeTo(1, 0.5);"," *"," * @name closeTo"," * @param {Number} expected"," * @param {Number} delta"," * @api public"," */","","Assertion.prototype.closeTo = function (expected, delta) {"," this.assert("," (this.obj - delta === expected) || (this.obj + delta === expected)"," , 'expected ' + this.inspect + ' to be close to ' + expected + ' +/- ' + delta"," , 'expected ' + this.inspect + ' not to be close to ' + expected + ' +/- ' + delta);",""," return this;","};","","/*!"," * Aliases."," */","","(function alias(name, as){"," Assertion.prototype[as] = Assertion.prototype[name];"," return alias;","})","('length', 'lengthOf')","('keys', 'key')","('ownProperty', 'haveOwnProperty')","('above', 'greaterThan')","('below', 'lessThan')","('throw', 'throws')","('throw', 'Throw') // for troublesome browsers","('instanceof', 'instanceOf');"];
View
59 node_modules/chai/lib-cov/chai.js
@@ -1,59 +0,0 @@
-/* automatically generated by JSCoverage - do not edit */
-if (typeof _$jscoverage === 'undefined') _$jscoverage = {};
-if (! _$jscoverage['chai.js']) {
- _$jscoverage['chai.js'] = [];
- _$jscoverage['chai.js'][7] = 0;
- _$jscoverage['chai.js'][8] = 0;
- _$jscoverage['chai.js'][10] = 0;
- _$jscoverage['chai.js'][12] = 0;
- _$jscoverage['chai.js'][13] = 0;
- _$jscoverage['chai.js'][15] = 0;
- _$jscoverage['chai.js'][17] = 0;
- _$jscoverage['chai.js'][18] = 0;
- _$jscoverage['chai.js'][19] = 0;
- _$jscoverage['chai.js'][20] = 0;
- _$jscoverage['chai.js'][23] = 0;
- _$jscoverage['chai.js'][26] = 0;
- _$jscoverage['chai.js'][27] = 0;
- _$jscoverage['chai.js'][29] = 0;
- _$jscoverage['chai.js'][30] = 0;
- _$jscoverage['chai.js'][32] = 0;
- _$jscoverage['chai.js'][33] = 0;
-}
-_$jscoverage['chai.js'][7]++;
-var used = [];
-_$jscoverage['chai.js'][8]++;
-var exports = module.exports = {};
-_$jscoverage['chai.js'][10]++;
-exports.version = "0.5.2";
-_$jscoverage['chai.js'][12]++;
-exports.Assertion = require("./assertion");
-_$jscoverage['chai.js'][13]++;
-exports.AssertionError = require("./error");
-_$jscoverage['chai.js'][15]++;
-exports.inspect = require("./utils/inspect");
-_$jscoverage['chai.js'][17]++;
-exports.use = (function (fn) {
- _$jscoverage['chai.js'][18]++;
- if (! ~ used.indexOf(fn)) {
- _$jscoverage['chai.js'][19]++;
- fn(this);
- _$jscoverage['chai.js'][20]++;
- used.push(fn);
- }
- _$jscoverage['chai.js'][23]++;
- return this;
-});
-_$jscoverage['chai.js'][26]++;
-var expect = require("./interface/expect");
-_$jscoverage['chai.js'][27]++;
-exports.use(expect);
-_$jscoverage['chai.js'][29]++;
-var should = require("./interface/should");
-_$jscoverage['chai.js'][30]++;
-exports.use(should);
-_$jscoverage['chai.js'][32]++;
-var assert = require("./interface/assert");
-_$jscoverage['chai.js'][33]++;
-exports.use(assert);
-_$jscoverage['chai.js'].source = ["/*!"," * chai"," * Copyright(c) 2011-2012 Jake Luer &lt;jake@alogicalparadox.com&gt;"," * MIT Licensed"," */","","var used = [];","var exports = module.exports = {};","","exports.version = '0.5.2';","","exports.Assertion = require('./assertion');","exports.AssertionError = require('./error');","","exports.inspect = require('./utils/inspect');","","exports.use = function (fn) {"," if (!~used.indexOf(fn)) {"," fn(this);"," used.push(fn);"," }",""," return this;","};","","var expect = require('./interface/expect');","exports.use(expect);","","var should = require('./interface/should');","exports.use(should);","","var assert = require('./interface/assert');","exports.use(assert);"];
View
54 node_modules/chai/lib-cov/error.js
@@ -1,54 +0,0 @@
-/* automatically generated by JSCoverage - do not edit */
-if (typeof _$jscoverage === 'undefined') _$jscoverage = {};
-if (! _$jscoverage['error.js']) {
- _$jscoverage['error.js'] = [];
- _$jscoverage['error.js'][7] = 0;
- _$jscoverage['error.js'][9] = 0;
- _$jscoverage['error.js'][15] = 0;
- _$jscoverage['error.js'][16] = 0;
- _$jscoverage['error.js'][17] = 0;
- _$jscoverage['error.js'][18] = 0;
- _$jscoverage['error.js'][19] = 0;
- _$jscoverage['error.js'][20] = 0;
- _$jscoverage['error.js'][21] = 0;
- _$jscoverage['error.js'][22] = 0;
- _$jscoverage['error.js'][24] = 0;
- _$jscoverage['error.js'][25] = 0;
- _$jscoverage['error.js'][29] = 0;
- _$jscoverage['error.js'][31] = 0;
- _$jscoverage['error.js'][32] = 0;
-}
-_$jscoverage['error.js'][7]++;
-var fail = require("./chai").fail;
-_$jscoverage['error.js'][9]++;
-module.exports = AssertionError;
-_$jscoverage['error.js'][15]++;
-function AssertionError(options) {
- _$jscoverage['error.js'][16]++;
- options = options || {};
- _$jscoverage['error.js'][17]++;
- this.name = "AssertionError";
- _$jscoverage['error.js'][18]++;
- this.message = options.message;
- _$jscoverage['error.js'][19]++;
- this.actual = options.actual;
- _$jscoverage['error.js'][20]++;
- this.expected = options.expected;
- _$jscoverage['error.js'][21]++;
- this.operator = options.operator;
- _$jscoverage['error.js'][22]++;
- var stackStartFunction = options.stackStartFunction || fail;
- _$jscoverage['error.js'][24]++;
- if (Error.captureStackTrace) {
- _$jscoverage['error.js'][25]++;
- Error.captureStackTrace(this, stackStartFunction);
- }
-}
-_$jscoverage['error.js'][29]++;
-AssertionError.prototype.__proto__ = Error.prototype;
-_$jscoverage['error.js'][31]++;
-AssertionError.prototype.toString = (function () {
- _$jscoverage['error.js'][32]++;
- return this.message;
-});
-_$jscoverage['error.js'].source = ["/*!"," * chai"," * Copyright(c) 2011 Jake Luer &lt;jake@alogicalparadox.com&gt;"," * MIT Licensed"," */","","var fail = require('./chai').fail;","","module.exports = AssertionError;","","/*!"," * Inspired by node.js assert module"," * https://github.com/joyent/node/blob/f8c335d0caf47f16d31413f89aa28eda3878e3aa/lib/assert.js"," */","function AssertionError (options) {"," options = options || {};"," this.name = 'AssertionError';"," this.message = options.message;"," this.actual = options.actual;"," this.expected = options.expected;"," this.operator = options.operator;"," var stackStartFunction = options.stackStartFunction || fail;",""," if (Error.captureStackTrace) {"," Error.captureStackTrace(this, stackStartFunction);"," }","}","","AssertionError.prototype.__proto__ = Error.prototype;","","AssertionError.prototype.toString = function() {"," return this.message;","};"];
View
281 node_modules/chai/lib-cov/interface/assert.js
@@ -1,281 +0,0 @@
-/* automatically generated by JSCoverage - do not edit */
-if (typeof _$jscoverage === 'undefined') _$jscoverage = {};
-if (! _$jscoverage['interface/assert.js']) {
- _$jscoverage['interface/assert.js'] = [];
- _$jscoverage['interface/assert.js'][31] = 0;
- _$jscoverage['interface/assert.js'][35] = 0;
- _$jscoverage['interface/assert.js'][42] = 0;
- _$jscoverage['interface/assert.js'][57] = 0;
- _$jscoverage['interface/assert.js'][58] = 0;
- _$jscoverage['interface/assert.js'][81] = 0;
- _$jscoverage['interface/assert.js'][82] = 0;
- _$jscoverage['interface/assert.js'][99] = 0;
- _$jscoverage['interface/assert.js'][100] = 0;
- _$jscoverage['interface/assert.js'][102] = 0;
- _$jscoverage['interface/assert.js'][122] = 0;
- _$jscoverage['interface/assert.js'][123] = 0;
- _$jscoverage['interface/assert.js'][125] = 0;
- _$jscoverage['interface/assert.js'][145] = 0;
- _$jscoverage['interface/assert.js'][146] = 0;
- _$jscoverage['interface/assert.js'][163] = 0;
- _$jscoverage['interface/assert.js'][164] = 0;
- _$jscoverage['interface/assert.js'][181] = 0;
- _$jscoverage['interface/assert.js'][182] = 0;
- _$jscoverage['interface/assert.js'][199] = 0;
- _$jscoverage['interface/assert.js'][200] = 0;
- _$jscoverage['interface/assert.js'][217] = 0;
- _$jscoverage['interface/assert.js'][218] = 0;
- _$jscoverage['interface/assert.js'][235] = 0;
- _$jscoverage['interface/assert.js'][236] = 0;
- _$jscoverage['interface/assert.js'][252] = 0;
- _$jscoverage['interface/assert.js'][253] = 0;
- _$jscoverage['interface/assert.js'][270] = 0;
- _$jscoverage['interface/assert.js'][271] = 0;
- _$jscoverage['interface/assert.js'][287] = 0;
- _$jscoverage['interface/assert.js'][288] = 0;
- _$jscoverage['interface/assert.js'][305] = 0;
- _$jscoverage['interface/assert.js'][306] = 0;
- _$jscoverage['interface/assert.js'][323] = 0;
- _$jscoverage['interface/assert.js'][324] = 0;
- _$jscoverage['interface/assert.js'][341] = 0;
- _$jscoverage['interface/assert.js'][342] = 0;
- _$jscoverage['interface/assert.js'][359] = 0;
- _$jscoverage['interface/assert.js'][360] = 0;
- _$jscoverage['interface/assert.js'][377] = 0;
- _$jscoverage['interface/assert.js'][378] = 0;
- _$jscoverage['interface/assert.js'][395] = 0;
- _$jscoverage['interface/assert.js'][396] = 0;
- _$jscoverage['interface/assert.js'][416] = 0;
- _$jscoverage['interface/assert.js'][417] = 0;
- _$jscoverage['interface/assert.js'][434] = 0;
- _$jscoverage['interface/assert.js'][435] = 0;
- _$jscoverage['interface/assert.js'][455] = 0;
- _$jscoverage['interface/assert.js'][456] = 0;
- _$jscoverage['interface/assert.js'][475] = 0;
- _$jscoverage['interface/assert.js'][476] = 0;
- _$jscoverage['interface/assert.js'][478] = 0;
- _$jscoverage['interface/assert.js'][479] = 0;
- _$jscoverage['interface/assert.js'][480] = 0;
- _$jscoverage['interface/assert.js'][481] = 0;
- _$jscoverage['interface/assert.js'][499] = 0;
- _$jscoverage['interface/assert.js'][500] = 0;
- _$jscoverage['interface/assert.js'][518] = 0;
- _$jscoverage['interface/assert.js'][519] = 0;
- _$jscoverage['interface/assert.js'][539] = 0;
- _$jscoverage['interface/assert.js'][540] = 0;
- _$jscoverage['interface/assert.js'][541] = 0;
- _$jscoverage['interface/assert.js'][542] = 0;
- _$jscoverage['interface/assert.js'][545] = 0;
- _$jscoverage['interface/assert.js'][565] = 0;
- _$jscoverage['interface/assert.js'][566] = 0;
- _$jscoverage['interface/assert.js'][567] = 0;
- _$jscoverage['interface/assert.js'][568] = 0;
- _$jscoverage['interface/assert.js'][571] = 0;
- _$jscoverage['interface/assert.js'][590] = 0;
- _$jscoverage['interface/assert.js'][591] = 0;
- _$jscoverage['interface/assert.js'][592] = 0;
- _$jscoverage['interface/assert.js'][594] = 0;
- _$jscoverage['interface/assert.js'][595] = 0;
- _$jscoverage['interface/assert.js'][605] = 0;
- _$jscoverage['interface/assert.js'][606] = 0;
- _$jscoverage['interface/assert.js'][613] = 0;
- _$jscoverage['interface/assert.js'][614] = 0;
- _$jscoverage['interface/assert.js'][615] = 0;
-}
-_$jscoverage['interface/assert.js'][31]++;
-module.exports = (function (chai) {
- _$jscoverage['interface/assert.js'][35]++;
- var Assertion = chai.Assertion, inspect = chai.inspect;
- _$jscoverage['interface/assert.js'][42]++;
- var assert = chai.assert = {};
- _$jscoverage['interface/assert.js'][57]++;
- assert.fail = (function (actual, expected, message, operator) {
- _$jscoverage['interface/assert.js'][58]++;
- throw new chai.AssertionError({actual: actual, expected: expected, message: message, operator: operator, stackStartFunction: assert.fail});
-});
- _$jscoverage['interface/assert.js'][81]++;
- assert.ok = (function (val, msg) {
- _$jscoverage['interface/assert.js'][82]++;
- new Assertion(val, msg).is.ok;
-});
- _$jscoverage['interface/assert.js'][99]++;
- assert.equal = (function (act, exp, msg) {
- _$jscoverage['interface/assert.js'][100]++;
- var test = new Assertion(act, msg);
- _$jscoverage['interface/assert.js'][102]++;
- test.assert(exp == test.obj, "expected " + test.inspect + " to equal " + inspect(exp), "expected " + test.inspect + " to not equal " + inspect(exp));
-});
- _$jscoverage['interface/assert.js'][122]++;
- assert.notEqual = (function (act, exp, msg) {
- _$jscoverage['interface/assert.js'][123]++;
- var test = new Assertion(act, msg);
- _$jscoverage['interface/assert.js'][125]++;
- test.assert(exp != test.obj, "expected " + test.inspect + " to equal " + inspect(exp), "expected " + test.inspect + " to not equal " + inspect(exp));
-});
- _$jscoverage['interface/assert.js'][145]++;
- assert.strictEqual = (function (act, exp, msg) {
- _$jscoverage['interface/assert.js'][146]++;
- new Assertion(act, msg).to.equal(exp);
-});
- _$jscoverage['interface/assert.js'][163]++;
- assert.notStrictEqual = (function (act, exp, msg) {
- _$jscoverage['interface/assert.js'][164]++;
- new Assertion(act, msg).to.not.equal(exp);
-});
- _$jscoverage['interface/assert.js'][181]++;
- assert.deepEqual = (function (act, exp, msg) {
- _$jscoverage['interface/assert.js'][182]++;
- new Assertion(act, msg).to.eql(exp);
-});
- _$jscoverage['interface/assert.js'][199]++;
- assert.notDeepEqual = (function (act, exp, msg) {
- _$jscoverage['interface/assert.js'][200]++;
- new Assertion(act, msg).to.not.eql(exp);
-});
- _$jscoverage['interface/assert.js'][217]++;
- assert.isTrue = (function (val, msg) {
- _$jscoverage['interface/assert.js'][218]++;
- new Assertion(val, msg).is["true"];
-});
- _$jscoverage['interface/assert.js'][235]++;
- assert.isFalse = (function (val, msg) {
- _$jscoverage['interface/assert.js'][236]++;
- new Assertion(val, msg).is["false"];
-});
- _$jscoverage['interface/assert.js'][252]++;
- assert.isNull = (function (val, msg) {
- _$jscoverage['interface/assert.js'][253]++;
- new Assertion(val, msg).to.equal(null);
-});
- _$jscoverage['interface/assert.js'][270]++;
- assert.isNotNull = (function (val, msg) {
- _$jscoverage['interface/assert.js'][271]++;
- new Assertion(val, msg).to.not.equal(null);
-});
- _$jscoverage['interface/assert.js'][287]++;
- assert.isUndefined = (function (val, msg) {
- _$jscoverage['interface/assert.js'][288]++;
- new Assertion(val, msg).to.equal(undefined);
-});
- _$jscoverage['interface/assert.js'][305]++;
- assert.isDefined = (function (val, msg) {
- _$jscoverage['interface/assert.js'][306]++;
- new Assertion(val, msg).to.not.equal(undefined);
-});
- _$jscoverage['interface/assert.js'][323]++;
- assert.isFunction = (function (val, msg) {
- _$jscoverage['interface/assert.js'][324]++;
- new Assertion(val, msg).to.be.a("function");
-});
- _$jscoverage['interface/assert.js'][341]++;
- assert.isObject = (function (val, msg) {
- _$jscoverage['interface/assert.js'][342]++;
- new Assertion(val, msg).to.be.a("object");
-});
- _$jscoverage['interface/assert.js'][359]++;
- assert.isArray = (function (val, msg) {
- _$jscoverage['interface/assert.js'][360]++;
- new Assertion(val, msg).to.be["instanceof"](Array);
-});
- _$jscoverage['interface/assert.js'][377]++;
- assert.isString = (function (val, msg) {
- _$jscoverage['interface/assert.js'][378]++;
- new Assertion(val, msg).to.be.a("string");
-});
- _$jscoverage['interface/assert.js'][395]++;
- assert.isNumber = (function (val, msg) {
- _$jscoverage['interface/assert.js'][396]++;
- new Assertion(val, msg).to.be.a("number");
-});
- _$jscoverage['interface/assert.js'][416]++;
- assert.isBoolean = (function (val, msg) {
- _$jscoverage['interface/assert.js'][417]++;
- new Assertion(val, msg).to.be.a("boolean");
-});
- _$jscoverage['interface/assert.js'][434]++;
- assert.typeOf = (function (val, type, msg) {
- _$jscoverage['interface/assert.js'][435]++;
- new Assertion(val, msg).to.be.a(type);
-});
- _$jscoverage['interface/assert.js'][455]++;
- assert.instanceOf = (function (val, type, msg) {
- _$jscoverage['interface/assert.js'][456]++;
- new Assertion(val, msg).to.be["instanceof"](type);
-});
- _$jscoverage['interface/assert.js'][475]++;
- assert.include = (function (exp, inc, msg) {
- _$jscoverage['interface/assert.js'][476]++;
- var obj = new Assertion(exp, msg);
- _$jscoverage['interface/assert.js'][478]++;
- if (Array.isArray(exp)) {
- _$jscoverage['interface/assert.js'][479]++;
- obj.to.include(inc);
- }
- else {
- _$jscoverage['interface/assert.js'][480]++;
- if ("string" === typeof exp) {
- _$jscoverage['interface/assert.js'][481]++;
- obj.to.contain.string(inc);
- }
- }
-});
- _$jscoverage['interface/assert.js'][499]++;
- assert.match = (function (exp, re, msg) {
- _$jscoverage['interface/assert.js'][500]++;
- new Assertion(exp, msg).to.match(re);
-});
- _$jscoverage['interface/assert.js'][518]++;
- assert.length = (function (exp, len, msg) {
- _$jscoverage['interface/assert.js'][519]++;
- new Assertion(exp, msg).to.have.length(len);
-});
- _$jscoverage['interface/assert.js'][539]++;
- assert["throws"] = (function (fn, type, msg) {
- _$jscoverage['interface/assert.js'][540]++;
- if ("string" === typeof type) {
- _$jscoverage['interface/assert.js'][541]++;
- msg = type;
- _$jscoverage['interface/assert.js'][542]++;
- type = null;
- }
- _$jscoverage['interface/assert.js'][545]++;
- new Assertion(fn, msg).to["throw"](type);
-});
- _$jscoverage['interface/assert.js'][565]++;
- assert.doesNotThrow = (function (fn, type, msg) {
- _$jscoverage['interface/assert.js'][566]++;
- if ("string" === typeof type) {
- _$jscoverage['interface/assert.js'][567]++;
- msg = type;
- _$jscoverage['interface/assert.js'][568]++;
- type = null;
- }
- _$jscoverage['interface/assert.js'][571]++;
- new Assertion(fn, msg).to.not["throw"](type);
-});
- _$jscoverage['interface/assert.js'][590]++;
- assert.operator = (function (val, operator, val2, msg) {
- _$jscoverage['interface/assert.js'][591]++;
- if (! ~ ["==", "===", ">", ">=", "<", "<=", "!=", "!=="].indexOf(operator)) {
- _$jscoverage['interface/assert.js'][592]++;
- throw new Error("Invalid operator \"" + operator + "\"");
- }
- _$jscoverage['interface/assert.js'][594]++;
- var test = new Assertion(eval(val + operator + val2), msg);
- _$jscoverage['interface/assert.js'][595]++;
- test.assert(true === test.obj, "expected " + inspect(val) + " to be " + operator + " " + inspect(val2), "expected " + inspect(val) + " to not be " + operator + " " + inspect(val2));
-});
- _$jscoverage['interface/assert.js'][605]++;
- assert.ifError = (function (val, msg) {
- _$jscoverage['interface/assert.js'][606]++;
- new Assertion(val, msg).to.not.be.ok;
-});
- _$jscoverage['interface/assert.js'][613]++;
- (function alias(name, as) {
- _$jscoverage['interface/assert.js'][614]++;
- assert[as] = assert[name];
- _$jscoverage['interface/assert.js'][615]++;
- return alias;
-})("length", "lengthOf")("throws", "throw");
-});
-_$jscoverage['interface/assert.js'].source = ["/*!"," * chai"," * Copyright(c) 2011 Jake Luer &lt;jake@alogicalparadox.com&gt;"," * MIT Licensed"," */","","/**"," * ### TDD Style Introduction"," *"," * The TDD style is exposed through `assert` interfaces. This provides"," * the classic assert.`test` notation, similiar to that packaged with"," * node.js. This assert module, however, provides several additional"," * tests and is browser compatible."," *"," * // assert"," * var assert = require('chai').assert;"," * , foo = 'bar';"," *"," * assert.typeOf(foo, 'string');"," * assert.equal(foo, 'bar');"," *"," * #### Configuration"," *"," * By default, Chai does not show stack traces upon an AssertionError. This can"," * be changed by modifying the `includeStack` parameter for chai.Assertion. For example:"," *"," * var chai = require('chai');"," * chai.Assertion.includeStack = true; // defaults to false"," */","","module.exports = function (chai) {"," /*!"," * Chai dependencies."," */"," var Assertion = chai.Assertion"," , inspect = chai.inspect;",""," /*!"," * Module export."," */",""," var assert = chai.assert = {};",""," /**"," * # .fail(actual, expect, msg, operator)"," *"," * Throw a failure. Node.js compatible."," *"," * @name fail"," * @param {*} actual value"," * @param {*} expected value"," * @param {String} message"," * @param {String} operator"," * @api public"," */",""," assert.fail = function (actual, expected, message, operator) {"," throw new chai.AssertionError({"," actual: actual"," , expected: expected"," , message: message"," , operator: operator"," , stackStartFunction: assert.fail"," });"," }",""," /**"," * # .ok(object, [message])"," *"," * Assert object is truthy."," *"," * assert.ok('everthing', 'everything is ok');"," * assert.ok(false, 'this will fail');"," *"," * @name ok"," * @param {*} object to test"," * @param {String} message"," * @api public"," */",""," assert.ok = function (val, msg) {"," new Assertion(val, msg).is.ok;"," };",""," /**"," * # .equal(actual, expected, [message])"," *"," * Assert strict equality."," *"," * assert.equal(3, 3, 'these numbers are equal');"," *"," * @name equal"," * @param {*} actual"," * @param {*} expected"," * @param {String} message"," * @api public"," */",""," assert.equal = function (act, exp, msg) {"," var test = new Assertion(act, msg);",""," test.assert("," exp == test.obj"," , 'expected ' + test.inspect + ' to equal ' + inspect(exp)"," , 'expected ' + test.inspect + ' to not equal ' + inspect(exp));"," };",""," /**"," * # .notEqual(actual, expected, [message])"," *"," * Assert not equal."," *"," * assert.notEqual(3, 4, 'these numbers are not equal');"," *"," * @name notEqual"," * @param {*} actual"," * @param {*} expected"," * @param {String} message"," * @api public"," */",""," assert.notEqual = function (act, exp, msg) {"," var test = new Assertion(act, msg);",""," test.assert("," exp != test.obj"," , 'expected ' + test.inspect + ' to equal ' + inspect(exp)"," , 'expected ' + test.inspect + ' to not equal ' + inspect(exp));"," };",""," /**"," * # .strictEqual(actual, expected, [message])"," *"," * Assert strict equality."," *"," * assert.strictEqual(true, true, 'these booleans are strictly equal');"," *"," * @name strictEqual"," * @param {*} actual"," * @param {*} expected"," * @param {String} message"," * @api public"," */",""," assert.strictEqual = function (act, exp, msg) {"," new Assertion(act, msg).to.equal(exp);"," };",""," /**"," * # .notStrictEqual(actual, expected, [message])"," *"," * Assert strict equality."," *"," * assert.notStrictEqual(1, true, 'these booleans are not strictly equal');"," *"," * @name notStrictEqual"," * @param {*} actual"," * @param {*} expected"," * @param {String} message"," * @api public"," */",""," assert.notStrictEqual = function (act, exp, msg) {"," new Assertion(act, msg).to.not.equal(exp);"," };",""," /**"," * # .deepEqual(actual, expected, [message])"," *"," * Assert not deep equality."," *"," * assert.deepEqual({ tea: 'green' }, { tea: 'green' });"," *"," * @name deepEqual"," * @param {*} actual"," * @param {*} expected"," * @param {String} message"," * @api public"," */",""," assert.deepEqual = function (act, exp, msg) {"," new Assertion(act, msg).to.eql(exp);"," };",""," /**"," * # .notDeepEqual(actual, expected, [message])"," *"," * Assert not deep equality."," *"," * assert.notDeepEqual({ tea: 'green' }, { tea: 'jasmine' });"," *"," * @name notDeepEqual"," * @param {*} actual"," * @param {*} expected"," * @param {String} message"," * @api public"," */",""," assert.notDeepEqual = function (act, exp, msg) {"," new Assertion(act, msg).to.not.eql(exp);"," };",""," /**"," * # .isTrue(value, [message])"," *"," * Assert `value` is true."," *"," * var tea_served = true;"," * assert.isTrue(tea_served, 'the tea has been served');"," *"," * @name isTrue"," * @param {Boolean} value"," * @param {String} message"," * @api public"," */",""," assert.isTrue = function (val, msg) {"," new Assertion(val, msg).is.true;"," };",""," /**"," * # .isFalse(value, [message])"," *"," * Assert `value` is false."," *"," * var tea_served = false;"," * assert.isFalse(tea_served, 'no tea yet? hmm...');"," *"," * @name isFalse"," * @param {Boolean} value"," * @param {String} message"," * @api public"," */",""," assert.isFalse = function (val, msg) {"," new Assertion(val, msg).is.false;"," };",""," /**"," * # .isNull(value, [message])"," *"," * Assert `value` is null."," *"," * assert.isNull(err, 'no errors');"," *"," * @name isNull"," * @param {*} value"," * @param {String} message"," * @api public"," */",""," assert.isNull = function (val, msg) {"," new Assertion(val, msg).to.equal(null);"," };",""," /**"," * # .isNotNull(value, [message])"," *"," * Assert `value` is not null."," *"," * var tea = 'tasty chai';"," * assert.isNotNull(tea, 'great, time for tea!');"," *"," * @name isNotNull"," * @param {*} value"," * @param {String} message"," * @api public"," */",""," assert.isNotNull = function (val, msg) {"," new Assertion(val, msg).to.not.equal(null);"," };",""," /**"," * # .isUndefined(value, [message])"," *"," * Assert `value` is undefined."," *"," * assert.isUndefined(tea, 'no tea defined');"," *"," * @name isUndefined"," * @param {*} value"," * @param {String} message"," * @api public"," */",""," assert.isUndefined = function (val, msg) {"," new Assertion(val, msg).to.equal(undefined);"," };",""," /**"," * # .isDefined(value, [message])"," *"," * Assert `value` is not undefined."," *"," * var tea = 'cup of chai';"," * assert.isDefined(tea, 'no tea defined');"," *"," * @name isUndefined"," * @param {*} value"," * @param {String} message"," * @api public"," */",""," assert.isDefined = function (val, msg) {"," new Assertion(val, msg).to.not.equal(undefined);"," };",""," /**"," * # .isFunction(value, [message])"," *"," * Assert `value` is a function."," *"," * var serve_tea = function () { return 'cup of tea'; };"," * assert.isFunction(serve_tea, 'great, we can have tea now');"," *"," * @name isFunction"," * @param {Function} value"," * @param {String} message"," * @api public"," */",""," assert.isFunction = function (val, msg) {"," new Assertion(val, msg).to.be.a('function');"," };",""," /**"," * # .isObject(value, [message])"," *"," * Assert `value` is an object."," *"," * var selection = { name: 'Chai', serve: 'with spices' };"," * assert.isObject(selection, 'tea selection is an object');"," *"," * @name isObject"," * @param {Object} value"," * @param {String} message"," * @api public"," */",""," assert.isObject = function (val, msg) {"," new Assertion(val, msg).to.be.a('object');"," };",""," /**"," * # .isArray(value, [message])"," *"," * Assert `value` is an instance of Array."," *"," * var menu = [ 'green', 'chai', 'oolong' ];"," * assert.isArray(menu, 'what kind of tea do we want?');"," *"," * @name isArray"," * @param {*} value"," * @param {String} message"," * @api public"," */",""," assert.isArray = function (val, msg) {"," new Assertion(val, msg).to.be.instanceof(Array);"," };",""," /**"," * # .isString(value, [message])"," *"," * Assert `value` is a string."," *"," * var teaorder = 'chai';"," * assert.isString(tea_order, 'order placed');"," *"," * @name isString"," * @param {String} value"," * @param {String} message"," * @api public"," */",""," assert.isString = function (val, msg) {"," new Assertion(val, msg).to.be.a('string');"," };",""," /**"," * # .isNumber(value, [message])"," *"," * Assert `value` is a number"," *"," * var cups = 2;"," * assert.isNumber(cups, 'how many cups');"," *"," * @name isNumber"," * @param {Number} value"," * @param {String} message"," * @api public"," */",""," assert.isNumber = function (val, msg) {"," new Assertion(val, msg).to.be.a('number');"," };",""," /**"," * # .isBoolean(value, [message])"," *"," * Assert `value` is a boolean"," *"," * var teaready = true"," * , teaserved = false;"," *"," * assert.isBoolean(tea_ready, 'is the tea ready');"," * assert.isBoolean(tea_served, 'has tea been served');"," *"," * @name isBoolean"," * @param {*} value"," * @param {String} message"," * @api public"," */",""," assert.isBoolean = function (val, msg) {"," new Assertion(val, msg).to.be.a('boolean');"," };",""," /**"," * # .typeOf(value, name, [message])"," *"," * Assert typeof `value` is `name`."," *"," * assert.typeOf('tea', 'string', 'we have a string');"," *"," * @name typeOf"," * @param {*} value"," * @param {String} typeof name"," * @param {String} message"," * @api public"," */",""," assert.typeOf = function (val, type, msg) {"," new Assertion(val, msg).to.be.a(type);"," };",""," /**"," * # .instanceOf(object, constructor, [message])"," *"," * Assert `value` is instanceof `constructor`."," *"," * var Tea = function (name) { this.name = name; }"," * , Chai = new Tea('chai');"," *"," * assert.instanceOf(Chai, Tea, 'chai is an instance of tea');"," *"," * @name instanceOf"," * @param {Object} object"," * @param {Constructor} constructor"," * @param {String} message"," * @api public"," */",""," assert.instanceOf = function (val, type, msg) {"," new Assertion(val, msg).to.be.instanceof(type);"," };",""," /**"," * # .include(value, includes, [message])"," *"," * Assert the inclusion of an object in another. Works"," * for strings and arrays."," *"," * assert.include('foobar', 'bar', 'foobar contains string `var`);"," * assert.include([ 1, 2, 3], 3, 'array contains value);"," *"," * @name include"," * @param {Array|String} value"," * @param {*} includes"," * @param {String} message"," * @api public"," */",""," assert.include = function (exp, inc, msg) {"," var obj = new Assertion(exp, msg);",""," if (Array.isArray(exp)) {"," obj.to.include(inc);"," } else if ('string' === typeof exp) {"," obj.to.contain.string(inc);"," }"," };",""," /**"," * # .match(value, regex, [message])"," *"," * Assert that `value` matches regular expression."," *"," * assert.match('foobar', /^foo/, 'Regexp matches');"," *"," * @name match"," * @param {*} value"," * @param {RegExp} RegularExpression"," * @param {String} message"," * @api public"," */",""," assert.match = function (exp, re, msg) {"," new Assertion(exp, msg).to.match(re);"," };",""," /**"," * # .length(value, constructor, [message])"," *"," * Assert that object has expected length."," *"," * assert.length([1,2,3], 3, 'Array has length of 3');"," * assert.length('foobar', 5, 'String has length of 6');"," *"," * @name length"," * @param {*} value"," * @param {Number} length"," * @param {String} message"," * @api public"," */",""," assert.length = function (exp, len, msg) {"," new Assertion(exp, msg).to.have.length(len);"," };",""," /**"," * # .throws(function, [constructor/regexp], [message])"," *"," * Assert that a function will throw a specific"," * type of error."," *"," * assert.throw(fn, ReferenceError, 'function throw reference error');"," *"," * @name throws"," * @alias throw"," * @param {Function} function to test"," * @param {ErrorConstructor} constructor"," * @param {String} message"," * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Error#Error_types"," * @api public"," */",""," assert.throws = function (fn, type, msg) {"," if ('string' === typeof type) {"," msg = type;"," type = null;"," }",""," new Assertion(fn, msg).to.throw(type);"," };",""," /**"," * # .doesNotThrow(function, [constructor/regexp], [message])"," *"," * Assert that a function will throw a specific"," * type of error."," *"," * var fn = function (err) { if (err) throw Error(err) };"," * assert.doesNotThrow(fn, Error, 'function throw reference error');"," *"," * @name doesNotThrow"," * @param {Function} function to test"," * @param {ErrorConstructor} constructor"," * @param {String} message"," * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Error#Error_types"," * @api public"," */",""," assert.doesNotThrow = function (fn, type, msg) {"," if ('string' === typeof type) {"," msg = type;"," type = null;"," }",""," new Assertion(fn, msg).to.not.throw(type);"," };",""," /**"," * # .operator(val, operator, val2, [message])"," *"," * Compare two values using operator."," *"," * assert.operator(1, '&lt;', 2, 'everything is ok');"," * assert.operator(1, '&gt;', 2, 'this will fail');"," *"," * @name operator"," * @param {*} object to test"," * @param {String} operator"," * @param {*} second object"," * @param {String} message"," * @api public"," */",""," assert.operator = function (val, operator, val2, msg) {"," if (!~['==', '===', '&gt;', '&gt;=', '&lt;', '&lt;=', '!=', '!=='].indexOf(operator)) {"," throw new Error('Invalid operator \"' + operator + '\"');"," }"," var test = new Assertion(eval(val + operator + val2), msg);"," test.assert("," true === test.obj"," , 'expected ' + inspect(val) + ' to be ' + operator + ' ' + inspect(val2)"," , 'expected ' + inspect(val) + ' to not be ' + operator + ' ' + inspect(val2) );"," };",""," /*!"," * Undocumented / untested"," */",""," assert.ifError = function (val, msg) {"," new Assertion(val, msg).to.not.be.ok;"," };",""," /*!"," * Aliases."," */",""," (function alias(name, as){"," assert[as] = assert[name];"," return alias;"," })"," ('length', 'lengthOf')"," ('throws', 'throw');","};"];
View
17 node_modules/chai/lib-cov/interface/expect.js
@@ -1,17 +0,0 @@
-/* automatically generated by JSCoverage - do not edit */
-if (typeof _$jscoverage === 'undefined') _$jscoverage = {};
-if (! _$jscoverage['interface/expect.js']) {
- _$jscoverage['interface/expect.js'] = [];
- _$jscoverage['interface/expect.js'][7] = 0;
- _$jscoverage['interface/expect.js'][8] = 0;
- _$jscoverage['interface/expect.js'][9] = 0;
-}
-_$jscoverage['interface/expect.js'][7]++;
-module.exports = (function (chai) {
- _$jscoverage['interface/expect.js'][8]++;
- chai.expect = (function (val, message) {
- _$jscoverage['interface/expect.js'][9]++;
- return new chai.Assertion(val, message);
-});
-});
-_$jscoverage['interface/expect.js'].source = ["/*!"," * chai"," * Copyright(c) 2011 Jake Luer &lt;jake@alogicalparadox.com&gt;"," * MIT Licensed"," */","","module.exports = function (chai) {"," chai.expect = function (val, message) {"," return new chai.Assertion(val, message);"," };","};",""];
View
92 node_modules/chai/lib-cov/interface/should.js
@@ -1,92 +0,0 @@
-/* automatically generated by JSCoverage - do not edit */
-if (typeof _$jscoverage === 'undefined') _$jscoverage = {};
-if (! _$jscoverage['interface/should.js']) {
- _$jscoverage['interface/should.js'] = [];
- _$jscoverage['interface/should.js'][7] = 0;
- _$jscoverage['interface/should.js'][8] = 0;
- _$jscoverage['interface/should.js'][10] = 0;
- _$jscoverage['interface/should.js'][12] = 0;
- _$jscoverage['interface/should.js'][15] = 0;
- _$jscoverage['interface/should.js'][16] = 0;
- _$jscoverage['interface/should.js'][17] = 0;
- _$jscoverage['interface/should.js'][18] = 0;
- _$jscoverage['interface/should.js'][20] = 0;
- _$jscoverage['interface/should.js'][25] = 0;
- _$jscoverage['interface/should.js'][27] = 0;
- _$jscoverage['interface/should.js'][28] = 0;
- _$jscoverage['interface/should.js'][31] = 0;
- _$jscoverage['interface/should.js'][32] = 0;
- _$jscoverage['interface/should.js'][35] = 0;
- _$jscoverage['interface/should.js'][36] = 0;
- _$jscoverage['interface/should.js'][40] = 0;
- _$jscoverage['interface/should.js'][42] = 0;
- _$jscoverage['interface/should.js'][43] = 0;
- _$jscoverage['interface/should.js'][46] = 0;
- _$jscoverage['interface/should.js'][47] = 0;
- _$jscoverage['interface/should.js'][50] = 0;
- _$jscoverage['interface/should.js'][51] = 0;
- _$jscoverage['interface/should.js'][54] = 0;
-}
-_$jscoverage['interface/should.js'][7]++;
-module.exports = (function (chai) {
- _$jscoverage['interface/should.js'][8]++;
- var Assertion = chai.Assertion;
- _$jscoverage['interface/should.js'][10]++;
- chai.should = (function () {
- _$jscoverage['interface/should.js'][12]++;
- Object.defineProperty(Object.prototype, "should", {set: (function () {
-}), get: (function () {
- _$jscoverage['interface/should.js'][15]++;
- if (this instanceof String || this instanceof Number) {
- _$jscoverage['interface/should.js'][16]++;
- return new Assertion(this.constructor(this));
- }
- else {
- _$jscoverage['interface/should.js'][17]++;
- if (this instanceof Boolean) {
- _$jscoverage['interface/should.js'][18]++;
- return new Assertion(this == true);
- }
- }
- _$jscoverage['interface/should.js'][20]++;
- return new Assertion(this);
-}), configurable: true});
- _$jscoverage['interface/should.js'][25]++;
- var should = {};
- _$jscoverage['interface/should.js'][27]++;
- should.equal = (function (val1, val2) {
- _$jscoverage['interface/should.js'][28]++;
- new Assertion(val1).to.equal(val2);
-});
- _$jscoverage['interface/should.js'][31]++;
- should["throw"] = (function (fn, errt, errs) {
- _$jscoverage['interface/should.js'][32]++;
- new Assertion(fn).to["throw"](errt, errs);
-});
- _$jscoverage['interface/should.js'][35]++;
- should.exist = (function (val) {
- _$jscoverage['interface/should.js'][36]++;
- new Assertion(val).to.exist;
-});
- _$jscoverage['interface/should.js'][40]++;
- should.not = {};
- _$jscoverage['interface/should.js'][42]++;
- should.not.equal = (function (val1, val2) {
- _$jscoverage['interface/should.js'][43]++;
- new Assertion(val1).to.not.equal(val2);
-});
- _$jscoverage['interface/should.js'][46]++;
- should.not["throw"] = (function (fn, errt, errs) {
- _$jscoverage['interface/should.js'][47]++;
- new Assertion(fn).to.not["throw"](errt, errs);
-});
- _$jscoverage['interface/should.js'][50]++;
- should.not.exist = (function (val) {
- _$jscoverage['interface/should.js'][51]++;
- new Assertion(val).to.not.exist;
-});
- _$jscoverage['interface/should.js'][54]++;
- return should;
-});
-});
-_$jscoverage['interface/should.js'].source = ["/*!"," * chai"," * Copyright(c) 2011 Jake Luer &lt;jake@alogicalparadox.com&gt;"," * MIT Licensed"," */","","module.exports = function (chai) {"," var Assertion = chai.Assertion;",""," chai.should = function () {"," // modify Object.prototype to have `should`"," Object.defineProperty(Object.prototype, 'should', {"," set: function(){},"," get: function(){"," if (this instanceof String || this instanceof Number) {"," return new Assertion(this.constructor(this));"," } else if (this instanceof Boolean) {"," return new Assertion(this == true);"," }"," return new Assertion(this);"," },"," configurable: true"," });",""," var should = {};",""," should.equal = function (val1, val2) {"," new Assertion(val1).to.equal(val2);"," };",""," should.throw = function (fn, errt, errs) {"," new Assertion(fn).to.throw(errt, errs);"," };",""," should.exist = function (val) {"," new Assertion(val).to.exist;"," }",""," // negation"," should.not = {}",""," should.not.equal = function (val1, val2) {"," new Assertion(val1).to.not.equal(val2);"," };",""," should.not.throw = function (fn, errt, errs) {"," new Assertion(fn).to.not.throw(errt, errs);"," };",""," should.not.exist = function (val) {"," new Assertion(val).to.not.exist;"," }",""," return should;"," };","};"];
View
182 node_modules/chai/lib-cov/utils/eql.js
@@ -1,182 +0,0 @@
-/* automatically generated by JSCoverage - do not edit */
-if (typeof _$jscoverage === 'undefined') _$jscoverage = {};
-if (! _$jscoverage['utils/eql.js']) {
- _$jscoverage['utils/eql.js'] = [];
- _$jscoverage['utils/eql.js'][5] = 0;
- _$jscoverage['utils/eql.js'][8] = 0;
- _$jscoverage['utils/eql.js'][9] = 0;
- _$jscoverage['utils/eql.js'][11] = 0;
- _$jscoverage['utils/eql.js'][16] = 0;
- _$jscoverage['utils/eql.js'][18] = 0;
- _$jscoverage['utils/eql.js'][19] = 0;
- _$jscoverage['utils/eql.js'][21] = 0;
- _$jscoverage['utils/eql.js'][22] = 0;
- _$jscoverage['utils/eql.js'][24] = 0;
- _$jscoverage['utils/eql.js'][25] = 0;
- _$jscoverage['utils/eql.js'][28] = 0;
- _$jscoverage['utils/eql.js'][32] = 0;
- _$jscoverage['utils/eql.js'][33] = 0;
- _$jscoverage['utils/eql.js'][37] = 0;
- _$jscoverage['utils/eql.js'][38] = 0;
- _$jscoverage['utils/eql.js'][47] = 0;
- _$jscoverage['utils/eql.js'][51] = 0;
- _$jscoverage['utils/eql.js'][52] = 0;
- _$jscoverage['utils/eql.js'][55] = 0;
- _$jscoverage['utils/eql.js'][56] = 0;
- _$jscoverage['utils/eql.js'][59] = 0;
- _$jscoverage['utils/eql.js'][60] = 0;
- _$jscoverage['utils/eql.js'][61] = 0;
- _$jscoverage['utils/eql.js'][63] = 0;
- _$jscoverage['utils/eql.js'][66] = 0;
- _$jscoverage['utils/eql.js'][67] = 0;
- _$jscoverage['utils/eql.js'][68] = 0;
- _$jscoverage['utils/eql.js'][70] = 0;
- _$jscoverage['utils/eql.js'][71] = 0;
- _$jscoverage['utils/eql.js'][72] = 0;
- _$jscoverage['utils/eql.js'][74] = 0;
- _$jscoverage['utils/eql.js'][75] = 0;
- _$jscoverage['utils/eql.js'][79] = 0;
- _$jscoverage['utils/eql.js'][83] = 0;
- _$jscoverage['utils/eql.js'][84] = 0;
- _$jscoverage['utils/eql.js'][86] = 0;
- _$jscoverage['utils/eql.js'][87] = 0;
- _$jscoverage['utils/eql.js'][89] = 0;
- _$jscoverage['utils/eql.js'][90] = 0;
- _$jscoverage['utils/eql.js'][91] = 0;
- _$jscoverage['utils/eql.js'][95] = 0;
- _$jscoverage['utils/eql.js'][96] = 0;
- _$jscoverage['utils/eql.js'][97] = 0;
- _$jscoverage['utils/eql.js'][99] = 0;
-}
-_$jscoverage['utils/eql.js'][5]++;
-module.exports = _deepEqual;
-_$jscoverage['utils/eql.js'][8]++;
-if (! Buffer) {
- _$jscoverage['utils/eql.js'][9]++;
- var Buffer = {isBuffer: (function () {
- _$jscoverage['utils/eql.js'][11]++;
- return false;
-})};
-}
-_$jscoverage['utils/eql.js'][16]++;
-function _deepEqual(actual, expected) {
- _$jscoverage['utils/eql.js'][18]++;
- if (actual === expected) {
- _$jscoverage['utils/eql.js'][19]++;
- return true;
- }
- else {
- _$jscoverage['utils/eql.js'][21]++;
- if (Buffer.isBuffer(actual) && Buffer.isBuffer(expected)) {
- _$jscoverage['utils/eql.js'][22]++;
- if (actual.length != expected.length) {
- _$jscoverage['utils/eql.js'][22]++;
- return false;
- }
- _$jscoverage['utils/eql.js'][24]++;
- for (var i = 0; i < actual.length; i++) {
- _$jscoverage['utils/eql.js'][25]++;
- if (actual[i] !== expected[i]) {
- _$jscoverage['utils/eql.js'][25]++;
- return false;
- }
-}
- _$jscoverage['utils/eql.js'][28]++;
- return true;
- }
- else {
- _$jscoverage['utils/eql.js'][32]++;
- if (actual instanceof Date && expected instanceof Date) {
- _$jscoverage['utils/eql.js'][33]++;
- return actual.getTime() === expected.getTime();
- }
- else {
- _$jscoverage['utils/eql.js'][37]++;
- if (typeof actual != "object" && typeof expected != "object") {
- _$jscoverage['utils/eql.js'][38]++;
- return actual === expected;
- }
- else {
- _$jscoverage['utils/eql.js'][47]++;
- return objEquiv(actual, expected);
- }
- }
- }
- }
-}
-_$jscoverage['utils/eql.js'][51]++;
-function isUndefinedOrNull(value) {
- _$jscoverage['utils/eql.js'][52]++;
- return value === null || value === undefined;
-}
-_$jscoverage['utils/eql.js'][55]++;
-function isArguments(object) {
- _$jscoverage['utils/eql.js'][56]++;
- return Object.prototype.toString.call(object) == "[object Arguments]";
-}
-_$jscoverage['utils/eql.js'][59]++;
-function objEquiv(a, b) {
- _$jscoverage['utils/eql.js'][60]++;
- if (isUndefinedOrNull(a) || isUndefinedOrNull(b)) {
- _$jscoverage['utils/eql.js'][61]++;
- return false;
- }
- _$jscoverage['utils/eql.js'][63]++;
- if (a.prototype !== b.prototype) {
- _$jscoverage['utils/eql.js'][63]++;
- return false;
- }
- _$jscoverage['utils/eql.js'][66]++;
- if (isArguments(a)) {
- _$jscoverage['utils/eql.js'][67]++;
- if (! isArguments(b)) {
- _$jscoverage['utils/eql.js'][68]++;
- return false;
- }
- _$jscoverage['utils/eql.js'][70]++;
- a = pSlice.call(a);
- _$jscoverage['utils/eql.js'][71]++;
- b = pSlice.call(b);
- _$jscoverage['utils/eql.js'][72]++;
- return _deepEqual(a, b);
- }
- _$jscoverage['utils/eql.js'][74]++;
- try {
- _$jscoverage['utils/eql.js'][75]++;
- var ka = Object.keys(a), kb = Object.keys(b), key, i;