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

hath-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

hath-assert

A set of hath assertions

latest
Source
npmnpm
Version
0.2.0
Version published
Weekly downloads
11
1000%
Maintainers
1
Weekly downloads
 
Created
Source

hath-asserts

Build Status

A set of assertion helpers for hath. PRs welcome.

API

  • require('hath-assert')([<Hath>])
  • t.assertEquals(<any>, <any>, [<message>])
  • t.assertNotEquals(<any>, <any>, [<message>])
  • t.assertMatches(<RegExp>, <any>, [<message>])
  • t.assertNotMatches(<RegExp>, <any>, [<message>])
  • t.assertTruthy(<any>, [<message>])
  • t.assertFalsey(<any>, [<message>])
  • t.assertError(<any>, [<message>])
  • t.assertThrows(<function>, [<RegExp>])

Example

const Hath = require('hath-assert')()

function testFoo(t, done) {
    t.assertEquals(1, 1)
    done()
}

module.exports = Hath.suite('Hath Assert Example', [
    testFoo
]);

if (module === require.main) {
  module.exports(new Hath());
}

Keywords

hath

FAQs

Package last updated on 28 Sep 2016

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