Tiny assertion library
$ npm install --save claim
var claim = require('claim');
claim.true(true);
claim.false(false);
claim.is('foo', 'foo');
claim.not('foo', 'bar');
claim.same(['a', 'b'], ['a', 'b']);
claim.notSame({a: 'a'}, {a: 'b'});
claim.regexTest(/^abc$/, 'abc');
Passing assertion.
Failing assertion.
Assert that value
is truthy.
Assert that value
is falsy.
Assert that value
is true
.
Assert that value
is false
.
Assert that value
is equal to expected
.
Assert that value
is not equal to expected
.
Assert that value
is deep equal to expected
.
Assert that value
is not deep equal to expected
.
Assert that function
throws an error.
error
can be a constructor, regex or validation function.
Assert that function
doesn't throw an error
.
Assert that regex
matches contents
.
Assert that error
is falsy.
MIT © Kevin Mårtensson