arbitrary-equivalence

1.0.5 • Public • Published
  • Compare -- Usage import configureCompare from 'compare' const compare = configureCompare(equivalenceVerifier, prepareLeftToPrint)

const { errCount, log } from compare(object_1, object_2)

errCount is a number

log is a multiple lines string (using \n) that can be passed as it is to a console.log, line this: console.log(log)

  • extendExpect -- Usage import extendExpect from 'compare' extendExpect(equivalenceVerifier, prepareLeftToPrint, testFramework)

Doing the above would make it possible to do like: expect(object_1).toBeEquivalent(object_2)

Readme

Keywords

none

Package Sidebar

Install

npm i arbitrary-equivalence

Weekly Downloads

6

Version

1.0.5

License

ISC

Last publish

Collaborators

  • rx.rossi