extends power-assert, izz, fuse-box-test-runner, chai assert & should... not just sure... fosho. throws if not
npm install fosho[![NPM version][fosho-npm-image]][fosho-npm-url]
[![MIT License][license-image]][license-url]
[![fliphub][gitter-badge]][gitter-url]
[![flipfam][flipfam-image]][flipfam-url]
[fosho-npm-image]: https://img.shields.io/npm/v/fosho.svg
[fosho-npm-url]: https://npmjs.org/package/fosho
[license-image]: http://img.shields.io/badge/license-MIT-blue.svg?style=flat
[license-url]: https://spdx.org/licenses/MIT
[gitter-badge]: https://img.shields.io/gitter/room/fliphub/pink.svg
[gitter-url]: https://gitter.im/fliphub/Lobby
[flipfam-image]: https://img.shields.io/badge/%F0%9F%8F%97%20%F0%9F%92%A0-flipfam-9659F7.svg
[flipfam-url]: https://www.npmjs.com/package/flipfam
> don't just be sure, be fosho.
!https://github.com/fliphub/fliphub
.isStr() or .str().aintReal()bash
yarn add fosho
npm i fosho --save
`📘 examples
$3
`js
const test = require('ava')
const fosho = require('fosho')class Workflow {}
test('fosho', (t) => {
fosho('eh')
.isReal()
.isStr().str() // long or short hands
.aintFunction()
const fnb = () => {}
function func() {}
fosho(fnb)
.fn()
.aintBindable()
fosho(func)
.isFunction()
.bindable()
.all(['function', 'bindable'])
fosho(fnb)
.fn()
.aintInstanceOf(Workflow)
fosho('nice boulder')
.str()
.findString('nice')
.findString('boulder')
fosho(['one'])
.lengthOf(1)
.typeOf('array')
fosho(1)
.beAbove(0)
.beBelow(2)
.isAbove(0)
.isBelow(2)
.above(-1)
.below(2)
})
test('fosho not a nice boulder...', (t) => {
t.throws(() => {
fosho({niceBoulder: true})
.isReal()
.isObj()
.instanceOf(Workflow)
})
})
// works with assertion planning
test('plan fosho', (t) => {
t.plan(2)
fosho({niceBoulder: true}, t)
.isReal()
.isObj()
})
`exports
it also exports fliplog chai assert and chai should
`js
const {fosho, log, should, assert} = require('chai')
``