🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis →
Socket
Book a DemoInstallSign in
Socket

expect-js-to-assert

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

expect-js-to-assert

A jscodeshift codemod that transforms from expect.js to Node assert

latest
Source
npmnpm
Version
0.2.0
Version published
Maintainers
1
Created
Source

expect-js-to-assert

A jscodeshift codemod that transforms from Automattic/expect.js to Node assert.

Build Status NPM version Code Style License

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

  • Takuto Wada

CONTRIBUTORS

LICENSE

Licensed under the MIT license.

Keywords

assert

FAQs

Package last updated on 28 Apr 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts