A jscodeshift codemod that transforms from Automattic/expect.js to Node assert.
$ npm install -g jscodeshift
$ npm install expect-js-to-assert
$ jscodeshift -t node_modules/expect-js-to-assert/transform.js target-dir
-
.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])
-
.not
-
.withArgs(...args)
Licensed under the MIT license.