Skip to content

Commit

Permalink
updated to power-assert-runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
Nuno Campos committed Jun 4, 2016
1 parent 60890c4 commit fc837f7
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 9 deletions.
1 change: 1 addition & 0 deletions lib/caching-precompiler.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@ CachingPrecompiler.prototype._createEspowerPlugin = function () {

// initialize power-assert
return createEspowerPlugin(this.babel, {
embedAst: true,
patterns: enhanceAssert.PATTERNS
});
};
Expand Down
12 changes: 6 additions & 6 deletions lib/enhance-assert.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,14 @@ function enhanceAssert(opts) {
}

function formatter() {
var powerAssertFormatter = require('power-assert-formatter');
var powerAssertRenderers = require('power-assert-renderers');
var createFormatter = require('power-assert-context-formatter');
var SuccinctRenderer = require('power-assert-renderer-succinct');
var AssertionRenderer = require('power-assert-renderer-assertion');

return powerAssertFormatter({
maxDepth: 3,
return createFormatter({
renderers: [
powerAssertRenderers.AssertionRenderer,
powerAssertRenderers.SuccinctRenderer
{ctor: AssertionRenderer},
{ctor: SuccinctRenderer, options: {maxDepth: 3}}
]
});
}
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
"babel-core": "^6.3.21",
"babel-plugin-ava-throws-helper": "0.0.4",
"babel-plugin-detective": "^1.0.2",
"babel-plugin-espower": "^2.1.0",
"babel-plugin-espower": "^2.2.0",
"babel-plugin-transform-runtime": "^6.3.13",
"babel-preset-es2015": "^6.3.13",
"babel-preset-stage-2": "^6.3.13",
Expand Down Expand Up @@ -132,8 +132,9 @@
"package-hash": "^1.1.0",
"pkg-conf": "^1.0.1",
"plur": "^2.0.0",
"power-assert-formatter": "^1.3.0",
"power-assert-renderers": "^0.1.0",
"power-assert-context-formatter": "^1.0.4",
"power-assert-renderer-assertion": "^1.0.1",
"power-assert-renderer-succinct": "^1.0.1",
"pretty-ms": "^2.0.0",
"repeating": "^2.0.0",
"require-precompiled": "^0.1.0",
Expand Down

0 comments on commit fc837f7

Please sign in to comment.