Skip to content

Commit

Permalink
Merge branch 'master' into feature/v3.0.0-with-generators
Browse files Browse the repository at this point in the history
* master: (25 commits)
  Fix mochajs#1798: Correctly attribute mutiple done err with hooks
  Remove redundant harmony flag
  Cast non-string return values from err.inspect()
  Call the inspect() function if message is not set
  Revert jade to support npm < v1.3.7
  Fix eqeqeq linting errors from eslint 1.4.0 release
  Fix mochajs#1669: catch uncaught errors outside test suite execution
  Support all harmony flags
  Fix fragile xunit reporter spec
  Fix linter warning "Expected a conditional expression and instead saw an assignment"
  Stackfilter fix: Don't remove modules/components from stack trace in the browser
  Fix mochajs#1864: xunit missing output with --reporter-options output
  Fix 1875: Markdown reporter exceeds maximum call stack size
  IE<=8 no [].reduce, so use 'utils.reduce' instead
  Release v2.3.2
  remove lodash.create; closes mochajs#1868
  update package.json & component.json for v2.3.1
  update HISTORY.md
  fix package.json to use exact version of lodash; closes mochajs#1867
  Fix: Bail flag causes before() hooks to be run even after a failure
  ...

# Conflicts:
#	lib/runnable.js
  • Loading branch information
kevinawoo committed Sep 14, 2015
2 parents 819c288 + 23b2955 commit e0272db
Show file tree
Hide file tree
Showing 39 changed files with 917 additions and 1,441 deletions.
151 changes: 130 additions & 21 deletions HISTORY.md
@@ -1,3 +1,112 @@
2.3.2 / 2015-09-07
==================
* [#1868] - Fix compatibility with older versions of NPM ([@boneskull])

[#1868]: https://github.com/mochajs/mocha/issues/1868

2.3.1 / 2015-09-06
==================

* [#1812] - Fix: Bail flag causes before() hooks to be run even after a failure ([@aaroncrows])

[#1812]: https://github.com/mochajs/mocha/issues/1812
[aaroncrows]: https://github.com/aaroncrows

2.3.0 / 2015-08-30
==================

* [#553] - added --allowUncaught option ([@amsul])
* [#1490] - Allow --async-only to be satisfied by returning a promise ([@jlai])
* [#1829] - support --max-old-space-size ([@gigadude])
* [#1811] - upgrade Jade dependency ([@outsideris])
* [#1769] - Fix async hook error handling ([@ajaykodali])
* [#1230] - More descriptive beforeEach/afterEach messages ([@duncanbeevers])
* [#1787] - Scope loading behaviour instead of using early return ([@aryeguy])
* [#1789] - Fix: html-runner crashing ([@sunesimonsen])
* [#1749] - Fix maximum call stack error on large amount of tests ([@tinganho])
* [#1230] - Decorate failed hook titles with test title ([@duncanbeevers])
* [#1260] - Build using Browserify ([@ndhoule])
* [#1728] - Don't use `__proto__` ([@ndhoule])
* [#1781] - Fix hook error tests ([@glenjamin])
* [#1754] - Allow boolean --reporter-options ([@papandreou])
* [#1766] - Fix overly aggressive stack suppression ([@moll])
* [#1752] - Avoid potential infinite loop ([@gsilk])
* [#1761] - Fix problems running under PhantomJS ([@chromakode])
* [#1700] - Fix more problems running under PhantomJS ([@jbnicolai])
* [#1774] - Support escaped spaces in CLI options ([@adamgruber])
* [#1687] - Fix HTML reporter links with special chars ([@benvinegar])
* [#1359] - Adopt code style and enforce it using ESLint ([@ndhoule] w/ assist from [@jbnicolai] & [@boneskull])
* various refactors ([@jbnicolai])
* [#1758] - Add cross-frame compatible Error checking ([@outdooricon])
* [#1741] - Remove moot `version` property from bower.json ([@kkirsche])
* [#1739] - Improve `HISTORY.md` ([@rstacruz])
* [#1730] - Support more io.js flags ([@ryedog])
* [#1349] - Allow HTML in HTML reporter errors ([@papandreou] / [@sunesimonsen])
* [#1572] - Prevent default browser behavior for failure/pass links ([@jschilli])
* [#1630] - Support underscored harmony flags ([@dominicbarnes])
* [#1718] - Support more harmony flags ([@slyg])
* [#1689] - Add stack to JSON-stream reporter ([@jonathandelgado])
* [#1654] - Fix `ReferenceError` "location is not defined" ([@jakemmarsh])

[#553]: https://github.com/mochajs/mocha/issues/553
[#1490]: https://github.com/mochajs/mocha/issues/1490
[#1829]: https://github.com/mochajs/mocha/issues/1829
[#1811]: https://github.com/mochajs/mocha/issues/1811
[#1769]: https://github.com/mochajs/mocha/issues/1769
[#1230]: https://github.com/mochajs/mocha/issues/1230
[#1787]: https://github.com/mochajs/mocha/issues/1787
[#1789]: https://github.com/mochajs/mocha/issues/1789
[#1749]: https://github.com/mochajs/mocha/issues/1749
[#1230]: https://github.com/mochajs/mocha/issues/1230
[#1260]: https://github.com/mochajs/mocha/issues/1260
[#1728]: https://github.com/mochajs/mocha/issues/1728
[#1781]: https://github.com/mochajs/mocha/issues/1781
[#1754]: https://github.com/mochajs/mocha/issues/1754
[#1766]: https://github.com/mochajs/mocha/issues/1766
[#1752]: https://github.com/mochajs/mocha/issues/1752
[#1761]: https://github.com/mochajs/mocha/issues/1761
[#1700]: https://github.com/mochajs/mocha/issues/1700
[#1774]: https://github.com/mochajs/mocha/issues/1774
[#1687]: https://github.com/mochajs/mocha/issues/1687
[#1359]: https://github.com/mochajs/mocha/issues/1359
[#1758]: https://github.com/mochajs/mocha/issues/1758
[#1741]: https://github.com/mochajs/mocha/issues/1741
[#1739]: https://github.com/mochajs/mocha/issues/1739
[#1730]: https://github.com/mochajs/mocha/issues/1730
[#1349]: https://github.com/mochajs/mocha/issues/1349
[#1572]: https://github.com/mochajs/mocha/issues/1572
[#1630]: https://github.com/mochajs/mocha/issues/1630
[#1718]: https://github.com/mochajs/mocha/issues/1718
[#1689]: https://github.com/mochajs/mocha/issues/1689
[#1654]: https://github.com/mochajs/mocha/issues/1654
[@adamgruber]: https://github.com/adamgruber
[@ajaykodali]: https://github.com/ajaykodali
[@amsul]: https://github.com/amsul
[@aryeguy]: https://github.com/aryeguy
[@benvinegar]: https://github.com/benvinegar
[@boneskull]: https://github.com/boneskull
[@chromakode]: https://github.com/chromakode
[@dominicbarnes]: https://github.com/dominicbarnes
[@duncanbeevers]: https://github.com/duncanbeevers
[@gigadude]: https://github.com/gigadude
[@glenjamin]: https://github.com/glenjamin
[@gsilk]: https://github.com/gsilk
[@jakemmarsh]: https://github.com/jakemmarsh
[@jbnicolai]: https://github.com/jbnicolai
[@jlai]: https://github.com/jlai
[@jonathandelgado]: https://github.com/jonathandelgado
[@jschilli]: https://github.com/jschilli
[@kkirsche]: https://github.com/kkirsche
[@moll]: https://github.com/moll
[@ndhoule]: https://github.com/ndhoule
[@outdooricon]: https://github.com/outdooricon
[@outsideris]: https://github.com/outsideris
[@papandreou]: https://github.com/papandreou
[@rstacruz]: https://github.com/rstacruz
[@ryedog]: https://github.com/ryedog
[@slyg]: https://github.com/slyg
[@sunesimonsen]: https://github.com/sunesimonsen
[@tinganho]: https://github.com/tinganho

2.2.5 / 2015-05-14
==================
Expand Down Expand Up @@ -34,27 +143,27 @@
==================

* fix(reporter/base): string diff - issue #1241
* fix(reporter/base): string diff - issue #1241
* fix(reporter/base): don't show diffs for errors without expectation
* fix(reporter/base): don't assume error message is first line of stack
* improve: dry up reporter/base test
* fix(reporter/base): explicitly ignore showDiff #1614
* Add iojs to travis build
* Pass `--allow-natives-syntax` flag to node.
* Support --harmony_classes flag for io.js
* Fix 1556: Update utils.clean to handle newlines in func declarations
* Fix 1606: fix err handling in IE <= 8 and non-ES5 browsers
* Fix 1585: make _mocha executable again
* chore(package.json): add a8m as a contributor
* Fixed broken link on html-cov reporter
* support --es_staging flag
* fix issue where menu overlaps content.
* update contributors in package.json
* Remove trailing whitespace from reporter output
* Remove contributors list from readme
* log third-party reporter errors
* [Fix] Exclude not own properties when looping on options
* fix: support node args in mocha.opts (close #1573)
* fix(reporter/base): string diff - issue #1241
* fix(reporter/base): don't show diffs for errors without expectation
* fix(reporter/base): don't assume error message is first line of stack
* improve: dry up reporter/base test
* fix(reporter/base): explicitly ignore showDiff #1614
* Add iojs to travis build
* Pass `--allow-natives-syntax` flag to node.
* Support --harmony_classes flag for io.js
* Fix 1556: Update utils.clean to handle newlines in func declarations
* Fix 1606: fix err handling in IE <= 8 and non-ES5 browsers
* Fix 1585: make _mocha executable again
* chore(package.json): add a8m as a contributor
* Fixed broken link on html-cov reporter
* support --es_staging flag
* fix issue where menu overlaps content.
* update contributors in package.json
* Remove trailing whitespace from reporter output
* Remove contributors list from readme
* log third-party reporter errors
* [Fix] Exclude not own properties when looping on options
* fix: support node args in mocha.opts (close #1573)
* fix(reporter/base): string diff - issue #1241

2.2.1 / 2015-03-09
Expand Down
10 changes: 1 addition & 9 deletions bin/_mocha
Expand Up @@ -81,16 +81,8 @@ program
.option('--compilers <ext>:<module>,...', 'use the given module(s) to compile files', list, [])
.option('--debug-brk', "enable node's debugger breaking on the first line")
.option('--globals <names>', 'allow the given comma-delimited global [names]', list, [])
.option('--harmony', 'enable all harmony features (except typeof)')
.option('--es_staging', 'enable all staged features')
.option('--harmony-collections', 'enable harmony collections (sets, maps, and weak maps)')
.option('--harmony-generators', 'enable harmony generators')
.option('--harmony-proxies', 'enable harmony proxies')
.option('--harmony_shipping', 'enable all shipped harmony fetaures (iojs)')
.option('--harmony_arrow_functions', 'enable "harmony arrow functions" (iojs)')
.option('--harmony_rest_parameters', 'enable "harmony rest parameters" (iojs)')
.option('--harmony_proxies', 'enable "harmony proxies" (iojs)')
.option('--harmony_classes', 'enable "harmony classes" (iojs)')
.option('--harmony<_classes,_generators,...>', 'all node --harmony* flags are available')
.option('--inline-diffs', 'display actual/expected differences inline within each string')
.option('--interfaces', 'display available interfaces')
.option('--no-deprecation', 'silence deprecation warnings')
Expand Down
20 changes: 2 additions & 18 deletions bin/mocha
Expand Up @@ -34,24 +34,7 @@ process.argv.slice(2).forEach(function(arg){
args.unshift('--expose-gc');
break;
case '--gc-global':
case '--harmony':
case '--es_staging':
case '--harmony_arrays':
case '--harmony_array_includes':
case '--harmony_arrow_functions':
case '--harmony_classes':
case '--harmony-collections':
case '--harmony_collections':
case '--harmony-generators':
case '--harmony_generators':
case '--harmony_modules':
case '--harmony-proxies':
case '--harmony_proxies':
case '--harmony_regexps':
case '--harmony_shipping':
case '--harmony_sloppy':
case '--harmony_rest_parameters':
case '--harmony_unicode':
case '--no-deprecation':
case '--prof':
case '--throw-deprecation':
Expand All @@ -60,7 +43,8 @@ process.argv.slice(2).forEach(function(arg){
args.unshift(arg);
break;
default:
if (0 == arg.indexOf('--trace')) args.unshift(arg);
if (0 == arg.indexOf('--harmony')) args.unshift(arg);
else if (0 == arg.indexOf('--trace')) args.unshift(arg);
else if (0 == arg.indexOf('--max-old-space-size')) args.unshift(arg);
else args.push(arg);
break;
Expand Down
4 changes: 2 additions & 2 deletions component.json
@@ -1,6 +1,6 @@
{
"name": "mocha",
"version": "2.2.5",
"version": "2.3.2",
"repo": "mochajs/mocha",
"description": "simple, flexible, fun test framework",
"keywords": [
Expand All @@ -17,4 +17,4 @@
"styles": [
"mocha.css"
]
}
}
7 changes: 2 additions & 5 deletions lib/hook.js
Expand Up @@ -3,7 +3,7 @@
*/

var Runnable = require('./runnable');
var create = require('lodash.create');
var inherits = require('./utils').inherits;

/**
* Expose `Hook`.
Expand All @@ -26,10 +26,7 @@ function Hook(title, fn) {
/**
* Inherit from `Runnable.prototype`.
*/

Hook.prototype = create(Runnable.prototype, {
constructor: Hook
});
inherits(Hook, Runnable);

/**
* Get or set the test `err`.
Expand Down

0 comments on commit e0272db

Please sign in to comment.