0.2.0 • Published 7 years ago
expect-js-to-assert v0.2.0
expect-js-to-assert
A jscodeshift codemod that transforms from Automattic/expect.js to Node assert.
USAGE
$ npm install -g jscodeshift
$ npm install expect-js-to-assert
$ jscodeshift -t node_modules/expect-js-to-assert/transform.js target-dir
FEATURES
matchers
.ok()
.be(value)
(alias.equal
).eql(value)
.a(type)
(alias.an
).match(regexp)
.contain(needle)
.length(size)
.empty()
.property(name, [value])
.key(name)
.keys(...name)
.throw([errorMatcher])
(alias.throwException
,.throwError
).within(start, finish)
.above(value)
(alias.greaterThan
).below(value)
(alias.lessThan
).fail([reason])
chains
.not
.withArgs(...args)
AUTHOR
CONTRIBUTORS
LICENSE
Licensed under the MIT license.