/*! Test.it v 0.6.1 | MIT | https://github.com/n2geoff/testit */ !function(t,e){"use strict";"object"==typeof module&&module.exports?module.exports=e(t.test):t.test=e(t.test)}(this,function(){"use strict";const t={_tests:{},run:function(t){let e=this._tests,r=[],o=[];return Object.keys(e).forEach(function(t){let n=e[t];try{n(),o.push(`\n+ ${t}`)}catch(e){r.push(`\n- ${t}`),console.error(e)}}),"function"==typeof t?t({pass:o,fail:r}):(console.log(...o,...r),console.log(`\n# tests ${r.length+o.length} pass ${o.length} fail ${r.length}`),!r.length)},it:function(t){return this._tests=t,this},expects:e=>({to:{be:{a:r=>t.expects(e).to.be.an(r),an:t=>{if(-1!==["array"].indexOf(t)){if("array"===e.constructor.name.toLowerCase())return!0;throw new Error(`expected ${typeof e} to be an ${t}`)}if(typeof e===t)return!0;throw new Error(`expected ${typeof e} to be an ${t}`)},like:t=>{if(e==t)return!0;throw new Error(`expected ${e} == ${t}`)}},equal:t=>{if(e===t)return!0;throw new Error(`expected ${e} === ${t}`)},exist:()=>{if(e)return!0;throw new Error(`expected ${e} to be truthy`)},pass:()=>!0,fail:t=>{throw new Error(t)}}})};return t});