Browse Source

[build]

master
Muthu Kumar 6 years ago
parent
commit
744381a412
  1. 104
      es5/dist.js
  2. 43
      es5/index.js
  3. 2
      package.json

104
es5/dist.js

@ -3,19 +3,19 @@ $jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.definePrope
$jscomp.polyfill=function(a,b,h,e){if(b){h=$jscomp.global;a=a.split(".");for(e=0;e<a.length-1;e++){var d=a[e];d in h||(h[d]={});h=h[d]}a=a[a.length-1];e=h[a];b=b(e);b!=e&&null!=b&&$jscomp.defineProperty(h,a,{configurable:!0,writable:!0,value:b})}};$jscomp.polyfill("Object.assign",function(a){return a||$jscomp.assign},"es6","es3");$jscomp.SYMBOL_PREFIX="jscomp_symbol_";$jscomp.initSymbol=function(){$jscomp.initSymbol=function(){};$jscomp.global.Symbol||($jscomp.global.Symbol=$jscomp.Symbol)};
$jscomp.Symbol=function(){var a=0;return function(b){return $jscomp.SYMBOL_PREFIX+(b||"")+a++}}();$jscomp.initSymbolIterator=function(){$jscomp.initSymbol();var a=$jscomp.global.Symbol.iterator;a||(a=$jscomp.global.Symbol.iterator=$jscomp.global.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&$jscomp.defineProperty(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return $jscomp.arrayIterator(this)}});$jscomp.initSymbolIterator=function(){}};
$jscomp.initSymbolAsyncIterator=function(){$jscomp.initSymbol();var a=$jscomp.global.Symbol.asyncIterator;a||(a=$jscomp.global.Symbol.asyncIterator=$jscomp.global.Symbol("asyncIterator"));$jscomp.initSymbolAsyncIterator=function(){}};$jscomp.arrayIterator=function(a){var b=0;return $jscomp.iteratorPrototype(function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}})};
$jscomp.iteratorPrototype=function(a){$jscomp.initSymbolIterator();a={next:a};a[$jscomp.global.Symbol.iterator]=function(){return this};return a};$jscomp.polyfill("Array.from",function(a){return a?a:function(a,h,e){$jscomp.initSymbolIterator();h=null!=h?h:function(c){return c};var b=[],l=a[Symbol.iterator];if("function"==typeof l){a=l.call(a);for(var c=0;!(l=a.next()).done;)b.push(h.call(e,l.value,c++))}else for(l=a.length,c=0;c<l;c++)b.push(h.call(e,a[c],c));return b}},"es6","es3");
$jscomp.iteratorPrototype=function(a){$jscomp.initSymbolIterator();a={next:a};a[$jscomp.global.Symbol.iterator]=function(){return this};return a};$jscomp.polyfill("Array.from",function(a){return a?a:function(a,h,e){$jscomp.initSymbolIterator();h=null!=h?h:function(c){return c};var b=[],m=a[Symbol.iterator];if("function"==typeof m){a=m.call(a);for(var c=0;!(m=a.next()).done;)b.push(h.call(e,m.value,c++))}else for(m=a.length,c=0;c<m;c++)b.push(h.call(e,a[c],c));return b}},"es6","es3");
$jscomp.iteratorFromArray=function(a,b){$jscomp.initSymbolIterator();a instanceof String&&(a+="");var h=0,e={next:function(){if(h<a.length){var d=h++;return{value:b(d,a[d]),done:!1}}e.next=function(){return{done:!0,value:void 0}};return e.next()}};e[Symbol.iterator]=function(){return e};return e};$jscomp.polyfill("Array.prototype.keys",function(a){return a?a:function(){return $jscomp.iteratorFromArray(this,function(a){return a})}},"es6","es3");
$jscomp.makeIterator=function(a){$jscomp.initSymbolIterator();var b=a[Symbol.iterator];return b?b.call(a):$jscomp.arrayIterator(a)};$jscomp.FORCE_POLYFILL_PROMISE=!1;
$jscomp.polyfill("Promise",function(a){function b(){this.batch_=null}function h(c){return c instanceof d?c:new d(function(a,b){a(c)})}if(a&&!$jscomp.FORCE_POLYFILL_PROMISE)return a;b.prototype.asyncExecute=function(c){null==this.batch_&&(this.batch_=[],this.asyncExecuteBatch_());this.batch_.push(c);return this};b.prototype.asyncExecuteBatch_=function(){var c=this;this.asyncExecuteFunction(function(){c.executeBatch_()})};var e=$jscomp.global.setTimeout;b.prototype.asyncExecuteFunction=function(c){e(c,
0)};b.prototype.executeBatch_=function(){for(;this.batch_&&this.batch_.length;){var c=this.batch_;this.batch_=[];for(var a=0;a<c.length;++a){var b=c[a];c[a]=null;try{b()}catch(f){this.asyncThrow_(f)}}}this.batch_=null};b.prototype.asyncThrow_=function(c){this.asyncExecuteFunction(function(){throw c;})};var d=function(c){this.state_=0;this.result_=void 0;this.onSettledCallbacks_=[];var a=this.createResolveAndReject_();try{c(a.resolve,a.reject)}catch(k){a.reject(k)}};d.prototype.createResolveAndReject_=
function(){function a(a){return function(c){k||(k=!0,a.call(b,c))}}var b=this,k=!1;return{resolve:a(this.resolveTo_),reject:a(this.reject_)}};d.prototype.resolveTo_=function(a){if(a===this)this.reject_(new TypeError("A Promise cannot resolve to itself"));else if(a instanceof d)this.settleSameAsPromise_(a);else{a:switch(typeof a){case "object":var c=null!=a;break a;case "function":c=!0;break a;default:c=!1}c?this.resolveToNonPromiseObj_(a):this.fulfill_(a)}};d.prototype.resolveToNonPromiseObj_=function(a){var c=
void 0;try{c=a.then}catch(k){this.reject_(k);return}"function"==typeof c?this.settleSameAsThenable_(c,a):this.fulfill_(a)};d.prototype.reject_=function(a){this.settle_(2,a)};d.prototype.fulfill_=function(a){this.settle_(1,a)};d.prototype.settle_=function(a,b){if(0!=this.state_)throw Error("Cannot settle("+a+", "+b+"): Promise already settled in state"+this.state_);this.state_=a;this.result_=b;this.executeOnSettledCallbacks_()};d.prototype.executeOnSettledCallbacks_=function(){if(null!=this.onSettledCallbacks_){for(var a=
0;a<this.onSettledCallbacks_.length;++a)l.asyncExecute(this.onSettledCallbacks_[a]);this.onSettledCallbacks_=null}};var l=new b;d.prototype.settleSameAsPromise_=function(a){var c=this.createResolveAndReject_();a.callWhenSettled_(c.resolve,c.reject)};d.prototype.settleSameAsThenable_=function(a,b){var c=this.createResolveAndReject_();try{a.call(b,c.resolve,c.reject)}catch(f){c.reject(f)}};d.prototype.then=function(a,b){function c(a,c){return"function"==typeof a?function(c){try{f(a(c))}catch(q){g(q)}}:
c}var f,g,e=new d(function(a,c){f=a;g=c});this.callWhenSettled_(c(a,f),c(b,g));return e};d.prototype.catch=function(a){return this.then(void 0,a)};d.prototype.callWhenSettled_=function(a,b){function c(){switch(f.state_){case 1:a(f.result_);break;case 2:b(f.result_);break;default:throw Error("Unexpected state: "+f.state_);}}var f=this;null==this.onSettledCallbacks_?l.asyncExecute(c):this.onSettledCallbacks_.push(c)};d.resolve=h;d.reject=function(a){return new d(function(c,b){b(a)})};d.race=function(a){return new d(function(c,
b){for(var f=$jscomp.makeIterator(a),k=f.next();!k.done;k=f.next())h(k.value).callWhenSettled_(c,b)})};d.all=function(a){var c=$jscomp.makeIterator(a),b=c.next();return b.done?h([]):new d(function(a,k){function f(c){return function(f){g[c]=f;m--;0==m&&a(g)}}var g=[],m=0;do g.push(void 0),m++,h(b.value).callWhenSettled_(f(g.length-1),k),b=c.next();while(!b.done)})};return d},"es6","es3");$jscomp.polyfill("Object.getOwnPropertySymbols",function(a){return a?a:function(){return[]}},"es6","es5");
$jscomp.polyfill("Reflect.ownKeys",function(a){return a?a:function(a){var b=[],e=Object.getOwnPropertyNames(a);a=Object.getOwnPropertySymbols(a);for(var d=0;d<e.length;d++)("jscomp_symbol_"==e[d].substring(0,14)?a:b).push(e[d]);return b.concat(a)}},"es6","es5");$jscomp.findInternal=function(a,b,h){a instanceof String&&(a=String(a));for(var e=a.length,d=0;d<e;d++){var l=a[d];if(b.call(h,l,d,a))return{i:d,v:l}}return{i:-1,v:void 0}};
$jscomp.polyfill("Promise",function(a){function b(){this.batch_=null}function h(c){return c instanceof d?c:new d(function(a,l){a(c)})}if(a&&!$jscomp.FORCE_POLYFILL_PROMISE)return a;b.prototype.asyncExecute=function(c){null==this.batch_&&(this.batch_=[],this.asyncExecuteBatch_());this.batch_.push(c);return this};b.prototype.asyncExecuteBatch_=function(){var c=this;this.asyncExecuteFunction(function(){c.executeBatch_()})};var e=$jscomp.global.setTimeout;b.prototype.asyncExecuteFunction=function(c){e(c,
0)};b.prototype.executeBatch_=function(){for(;this.batch_&&this.batch_.length;){var c=this.batch_;this.batch_=[];for(var a=0;a<c.length;++a){var l=c[a];c[a]=null;try{l()}catch(f){this.asyncThrow_(f)}}}this.batch_=null};b.prototype.asyncThrow_=function(c){this.asyncExecuteFunction(function(){throw c;})};var d=function(c){this.state_=0;this.result_=void 0;this.onSettledCallbacks_=[];var a=this.createResolveAndReject_();try{c(a.resolve,a.reject)}catch(l){a.reject(l)}};d.prototype.createResolveAndReject_=
function(){function c(c){return function(f){l||(l=!0,c.call(a,f))}}var a=this,l=!1;return{resolve:c(this.resolveTo_),reject:c(this.reject_)}};d.prototype.resolveTo_=function(c){if(c===this)this.reject_(new TypeError("A Promise cannot resolve to itself"));else if(c instanceof d)this.settleSameAsPromise_(c);else{a:switch(typeof c){case "object":var a=null!=c;break a;case "function":a=!0;break a;default:a=!1}a?this.resolveToNonPromiseObj_(c):this.fulfill_(c)}};d.prototype.resolveToNonPromiseObj_=function(a){var c=
void 0;try{c=a.then}catch(l){this.reject_(l);return}"function"==typeof c?this.settleSameAsThenable_(c,a):this.fulfill_(a)};d.prototype.reject_=function(a){this.settle_(2,a)};d.prototype.fulfill_=function(a){this.settle_(1,a)};d.prototype.settle_=function(a,b){if(0!=this.state_)throw Error("Cannot settle("+a+", "+b+"): Promise already settled in state"+this.state_);this.state_=a;this.result_=b;this.executeOnSettledCallbacks_()};d.prototype.executeOnSettledCallbacks_=function(){if(null!=this.onSettledCallbacks_){for(var a=
0;a<this.onSettledCallbacks_.length;++a)m.asyncExecute(this.onSettledCallbacks_[a]);this.onSettledCallbacks_=null}};var m=new b;d.prototype.settleSameAsPromise_=function(a){var c=this.createResolveAndReject_();a.callWhenSettled_(c.resolve,c.reject)};d.prototype.settleSameAsThenable_=function(a,b){var c=this.createResolveAndReject_();try{a.call(b,c.resolve,c.reject)}catch(f){c.reject(f)}};d.prototype.then=function(a,b){function c(a,c){return"function"==typeof a?function(c){try{f(a(c))}catch(q){k(q)}}:
c}var f,k,g=new d(function(a,c){f=a;k=c});this.callWhenSettled_(c(a,f),c(b,k));return g};d.prototype.catch=function(a){return this.then(void 0,a)};d.prototype.callWhenSettled_=function(a,b){function c(){switch(f.state_){case 1:a(f.result_);break;case 2:b(f.result_);break;default:throw Error("Unexpected state: "+f.state_);}}var f=this;null==this.onSettledCallbacks_?m.asyncExecute(c):this.onSettledCallbacks_.push(c)};d.resolve=h;d.reject=function(a){return new d(function(c,b){b(a)})};d.race=function(a){return new d(function(c,
b){for(var f=$jscomp.makeIterator(a),l=f.next();!l.done;l=f.next())h(l.value).callWhenSettled_(c,b)})};d.all=function(a){var c=$jscomp.makeIterator(a),b=c.next();return b.done?h([]):new d(function(a,l){function f(c){return function(f){k[c]=f;g--;0==g&&a(k)}}var k=[],g=0;do k.push(void 0),g++,h(b.value).callWhenSettled_(f(k.length-1),l),b=c.next();while(!b.done)})};return d},"es6","es3");$jscomp.polyfill("Object.getOwnPropertySymbols",function(a){return a?a:function(){return[]}},"es6","es5");
$jscomp.polyfill("Reflect.ownKeys",function(a){return a?a:function(a){var b=[],e=Object.getOwnPropertyNames(a);a=Object.getOwnPropertySymbols(a);for(var d=0;d<e.length;d++)("jscomp_symbol_"==e[d].substring(0,14)?a:b).push(e[d]);return b.concat(a)}},"es6","es5");$jscomp.findInternal=function(a,b,h){a instanceof String&&(a=String(a));for(var e=a.length,d=0;d<e;d++){var m=a[d];if(b.call(h,m,d,a))return{i:d,v:m}}return{i:-1,v:void 0}};
$jscomp.polyfill("Array.prototype.find",function(a){return a?a:function(a,h){return $jscomp.findInternal(this,a,h).v}},"es6","es3");$jscomp.polyfill("Array.prototype.findIndex",function(a){return a?a:function(a,h){return $jscomp.findInternal(this,a,h).i}},"es6","es3");
var _slicedToArray=function(){return function(a,b){if(Array.isArray(a))return a;if(Symbol.iterator in Object(a)){var h=[],e=!0,d=!1,l=void 0;try{for(var c=a[Symbol.iterator](),g;!(e=(g=c.next()).done)&&(h.push(g.value),!b||h.length!==b);e=!0);}catch(k){d=!0,l=k}finally{try{if(!e&&c["return"])c["return"]()}finally{if(d)throw l;}}return h}throw new TypeError("Invalid attempt to destructure non-iterable instance");}}(),_createClass=function(){function a(a,h){for(var b=0;b<h.length;b++){var d=h[b];d.enumerable=
var _slicedToArray=function(){return function(a,b){if(Array.isArray(a))return a;if(Symbol.iterator in Object(a)){var h=[],e=!0,d=!1,m=void 0;try{for(var c=a[Symbol.iterator](),g;!(e=(g=c.next()).done)&&(h.push(g.value),!b||h.length!==b);e=!0);}catch(l){d=!0,m=l}finally{try{if(!e&&c["return"])c["return"]()}finally{if(d)throw m;}}return h}throw new TypeError("Invalid attempt to destructure non-iterable instance");}}(),_createClass=function(){function a(a,h){for(var b=0;b<h.length;b++){var d=h[b];d.enumerable=
d.enumerable||!1;d.configurable=!0;"value"in d&&(d.writable=!0);Object.defineProperty(a,d.key,d)}}return function(b,h,e){h&&a(b.prototype,h);e&&a(b,e);return b}}(),_extends2=Object.assign||function(a){for(var b=1;b<arguments.length;b++){var h=arguments[b],e;for(e in h)Object.prototype.hasOwnProperty.call(h,e)&&(a[e]=h[e])}return a},_typeof2="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"===typeof Symbol&&a.constructor===Symbol&&
a!==Symbol.prototype?"symbol":typeof a},_templateObject=_taggedTemplateLiteral([""," is not an array"],[""," is not an array"]),_templateObject2=_taggedTemplateLiteral([""," is not an object"],[""," is not an object"]),_templateObject3=_taggedTemplateLiteral([""," doesn't have length ",""],[""," doesn't have length ",""]),_templateObject4=_taggedTemplateLiteral([""," is not equal to ",""],[""," is not equal to ",""]),_templateObject5=_taggedTemplateLiteral([""," is not deeply equal to ",""],[""," is not deeply equal to ",
""]),_templateObject6=_taggedTemplateLiteral([""," does not contain ",""],[""," does not contain ",""]),_templateObject7=_taggedTemplateLiteral([""," is not true"],[""," is not true"]),_templateObject8=_taggedTemplateLiteral([""," is not false"],[""," is not false"]),_templateObject9=_taggedTemplateLiteral([""," does not have property '","'"],[""," does not have property '","'"]),_templateObject10=_taggedTemplateLiteral([""," does not exist in ",""],[""," does not exist in ",""]),_templateObject11=
@ -23,60 +23,60 @@ _taggedTemplateLiteral([""," is not a promise"],[""," is not a promise"]),_templ
""]),_templateObject16=_taggedTemplateLiteral(["'","' is less than ",""],["'","' is less than ",""]),_templateObject17=_taggedTemplateLiteral(["'","' is greater than ",""],["'","' is greater than ",""]);function _possibleConstructorReturn(a,b){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!b||"object"!==typeof b&&"function"!==typeof b?a:b}
function _inherits(a,b){if("function"!==typeof b&&null!==b)throw new TypeError("Super expression must either be null or a function, not "+typeof b);a.prototype=Object.create(b&&b.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}});b&&(Object.setPrototypeOf?Object.setPrototypeOf(a,b):a.__proto__=b)}function _taggedTemplateLiteral(a,b){return Object.freeze(Object.defineProperties(a,{raw:{value:Object.freeze(b)}}))}
function _toArray(a){return Array.isArray(a)?a:Array.from(a)}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function");}function _defineProperty2(a,b,h){b in a?Object.defineProperty(a,b,{value:h,enumerable:!0,configurable:!0,writable:!0}):a[b]=h;return a}function _toConsumableArray2(a){if(Array.isArray(a)){for(var b=0,h=Array(a.length);b<a.length;b++)h[b]=a[b];return h}return Array.from(a)}
(function(a){"object"===("undefined"===typeof exports?"undefined":_typeof2(exports))&&"undefined"!==typeof module?module.exports=a():"function"===typeof define&&define.amd?define([],a):("undefined"!==typeof window?window:"undefined"!==typeof global?global:"undefined"!==typeof self?self:this).Gunner=a()})(function(){return function(){function a(b,h,e){function d(c,k){if(!h[c]){if(!b[c]){var f="function"==typeof require&&require;if(!k&&f)return f(c,!0);if(l)return l(c,!0);k=Error("Cannot find module '"+
c+"'");throw k.code="MODULE_NOT_FOUND",k;}k=h[c]={exports:{}};b[c][0].call(k.exports,function(a){return d(b[c][1][a]||a)},k,k.exports,a,b,h,e)}return h[c].exports}for(var l="function"==typeof require&&require,c=0;c<e.length;c++)d(e[c]);return d}return a}()({1:[function(a,b,h){b.exports=a("../src/gunner")},{"../src/gunner":9}],2:[function(a,b,h){(function(e){(function(a){"object"===("undefined"===typeof h?"undefined":_typeof2(h))&&"undefined"!==typeof b?b.exports=a():("undefined"!==typeof window?window:
"undefined"!==typeof e?e:"undefined"!==typeof self?self:this).isEq=a()})(function(){return function(){function b(e,c,g){function k(m,d){if(!c[m]){if(!e[m]){var l="function"==typeof a&&a;if(!d&&l)return l(m,!0);if(f)return f(m,!0);d=Error("Cannot find module '"+m+"'");throw d.code="MODULE_NOT_FOUND",d;}d=c[m]={exports:{}};e[m][0].call(d.exports,function(a){var c=e[m][1][a];return k(c?c:a)},d,d.exports,b,e,c,g)}return c[m].exports}for(var f="function"==typeof a&&a,m=0;m<g.length;m++)k(g[m]);return k}
(function(a){"object"===("undefined"===typeof exports?"undefined":_typeof2(exports))&&"undefined"!==typeof module?module.exports=a():"function"===typeof define&&define.amd?define([],a):("undefined"!==typeof window?window:"undefined"!==typeof global?global:"undefined"!==typeof self?self:this).Gunner=a()})(function(){return function(){function a(b,h,e){function d(c,l){if(!h[c]){if(!b[c]){var f="function"==typeof require&&require;if(!l&&f)return f(c,!0);if(m)return m(c,!0);l=Error("Cannot find module '"+
c+"'");throw l.code="MODULE_NOT_FOUND",l;}l=h[c]={exports:{}};b[c][0].call(l.exports,function(a){return d(b[c][1][a]||a)},l,l.exports,a,b,h,e)}return h[c].exports}for(var m="function"==typeof require&&require,c=0;c<e.length;c++)d(e[c]);return d}return a}()({1:[function(a,b,h){b.exports=a("../src/gunner")},{"../src/gunner":9}],2:[function(a,b,h){(function(e){(function(a){"object"===("undefined"===typeof h?"undefined":_typeof2(h))&&"undefined"!==typeof b?b.exports=a():("undefined"!==typeof window?window:
"undefined"!==typeof e?e:"undefined"!==typeof self?self:this).isEq=a()})(function(){return function(){function b(d,c,g){function l(k,e){if(!c[k]){if(!d[k]){var m="function"==typeof a&&a;if(!e&&m)return m(k,!0);if(f)return f(k,!0);e=Error("Cannot find module '"+k+"'");throw e.code="MODULE_NOT_FOUND",e;}e=c[k]={exports:{}};d[k][0].call(e.exports,function(a){var c=d[k][1][a];return l(c?c:a)},e,e.exports,b,d,c,g)}return c[k].exports}for(var f="function"==typeof a&&a,k=0;k<g.length;k++)l(g[k]);return l}
return b}()({1:[function(a,b,c){var g="function"===typeof Symbol&&"symbol"===_typeof2(Symbol.iterator)?function(a){return"undefined"===typeof a?"undefined":_typeof2(a)}:function(a){return a&&"function"===typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":"undefined"===typeof a?"undefined":_typeof2(a)};b.exports=function n(a,c,b){if(a===c)return!0;if(("undefined"===typeof a?"undefined":g(a))!==("undefined"===typeof c?"undefined":g(c))||Array.isArray(a)&&!Array.isArray(c)||Array.isArray(c)&&
!Array.isArray(a))return!1;if("number"===typeof a)return isNaN(a)&&isNaN(c)?!1:a===c;if("string"===typeof a||"boolean"===typeof a||null===a||void 0===a)return a===c;if(a instanceof RegExp)return String(a)===String(c);if("object"!==("undefined"===typeof a?"undefined":g(a))||"object"!==("undefined"===typeof c?"undefined":g(c)))return a===c;var f=Object.keys(a),d=Object.keys(c);if(!b&&(b=f,f.length!==d.length))return!1;if(!Array.isArray(b))throw Error("[isEq] third parameter should be an array of keys!");
if(0===b.length)return!0;for(var e in b)if(f=b[e],Array.isArray(a[f])&&Array.isArray(c[f])&&(f=e),a[f]!==c[f])if(g("object"===a[f])&&g("object"===c[f])||Array.isArray(a[f])&&Array.isArray(c[f])){if(!n(a[f],c[f]))return!1}else return!1;return!0}},{}]},{},[1])(1)})}).call(this,"undefined"!==typeof global?global:"undefined"!==typeof self?self:"undefined"!==typeof window?window:{})},{}],3:[function(a,b,h){(function(e){function d(a,c,b){c in a?Object.defineProperty(a,c,{value:b,enumerable:!0,configurable:!0,
writable:!0}):a[c]=b;return a}function l(a){if(Array.isArray(a)){for(var c=0,b=Array(a.length);c<a.length;c++)b[c]=a[c];return b}return Array.from(a)}var c=Object.assign||function(a){for(var c=1;c<arguments.length;c++){var b=arguments[c],g;for(g in b)Object.prototype.hasOwnProperty.call(b,g)&&(a[g]=b[g])}return a},g="function"===typeof Symbol&&"symbol"===_typeof2(Symbol.iterator)?function(a){return"undefined"===typeof a?"undefined":_typeof2(a)}:function(a){return a&&"function"===typeof Symbol&&a.constructor===
Symbol&&a!==Symbol.prototype?"symbol":"undefined"===typeof a?"undefined":_typeof2(a)};(function(a){"object"===("undefined"===typeof h?"undefined":g(h))&&"undefined"!==typeof b?b.exports=a():("undefined"!==typeof window?window:"undefined"!==typeof e?e:"undefined"!==typeof self?self:this).promiseObject=a()})(function(){return function(){function c(b,g,d){function f(k,m){if(!g[k]){if(!b[k]){var l="function"==typeof a&&a;if(!m&&l)return l(k,!0);if(e)return e(k,!0);m=Error("Cannot find module '"+k+"'");
throw m.code="MODULE_NOT_FOUND",m;}m=g[k]={exports:{}};b[k][0].call(m.exports,function(a){return f(b[k][1][a]||a)},m,m.exports,c,b,g,d)}return g[k].exports}for(var e="function"==typeof a&&a,k=0;k<d.length;k++)f(d[k]);return f}return c}()({1:[function(a,c,b){c.exports=a("../index.js")},{"../index.js":2}],2:[function(a,b,e){var f=function(a){return a&&"object"===("undefined"===typeof a?"undefined":g(a))&&a.constructor===Object},k="undefined"!==typeof Symbol?Symbol("SELF"):"[~~//-- SELF --//~~]",m=function(a,
c){return function w(b){return Object.keys(b).reduce(function(g,d){var e=b[d];return e===c?(b[d]=a,[].concat(l(g),[d])):f(e)?[].concat(l(g),l(w(e,c))):g},[])}(a)},h=function(a,c){return Promise.all(a.map(function(a){return Promise.resolve(a).then(c)}))},q=function(a){return Promise.all(Object.keys(a).map(function(c){return Promise.resolve(a[c]).then(function(b){return a[c]=b})})).then(function(c){return a})};b.exports=function(a){var b=!1;return function w(g){return Promise.resolve(g).then(function(g){return Array.isArray(g)?
h(g,function(a){return w(a)}):f(g)?q(Object.keys(g).reduce(function(f,e){return g[e]===a?(b=!0,c({},f,d({},e,k))):c({},f,d({},e,w(g[e])))},{})):g})}(a).then(function(a){b&&m(a,k);return a})}},{}]},{},[1])(1)})}).call(this,"undefined"!==typeof global?global:"undefined"!==typeof self?self:"undefined"!==typeof window?window:{})},{"../index.js":4}],4:[function(a,b,h){var e=function(a){return a&&"object"===("undefined"===typeof a?"undefined":_typeof2(a))&&a.constructor===Object},d="undefined"!==typeof Symbol?
Symbol("SELF"):"[~~//-- SELF --//~~]",l=function(a,c){return function n(b){return Object.keys(b).reduce(function(f,g){var d=b[g];return d===c?(b[g]=a,[].concat(_toConsumableArray2(f),[g])):e(d)?[].concat(_toConsumableArray2(f),_toConsumableArray2(n(d,c))):f},[])}(a)},c=function(a,c){return Promise.all(a.map(function(a){return Promise.resolve(a).then(c)}))},g=function(a){return Promise.all(Object.keys(a).map(function(c){return Promise.resolve(a[c]).then(function(b){return a[c]=b})})).then(function(c){return a})};
b.exports=function(a){var b=!1;return function n(f){return Promise.resolve(f).then(function(f){return Array.isArray(f)?c(f,function(a){return n(a)}):e(f)?g(Object.keys(f).reduce(function(c,g){return f[g]===a?(b=!0,_extends2({},c,_defineProperty2({},g,d))):_extends2({},c,_defineProperty2({},g,n(f[g])))},{})):f})}(a).then(function(a){b&&l(a,d);return a})}},{}],5:[function(a,b,h){},{}],6:[function(a,b,h){function e(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=p(null),
!Array.isArray(a))return!1;if("number"===typeof a)return isNaN(a)&&isNaN(c)?!1:a===c;if("string"===typeof a||"boolean"===typeof a||null===a||void 0===a)return a===c;if(a instanceof RegExp)return String(a)===String(c);if("object"!==("undefined"===typeof a?"undefined":g(a))||"object"!==("undefined"===typeof c?"undefined":g(c)))return a===c;var f=Object.keys(a),k=Object.keys(c);if(!b&&(b=f,f.length!==k.length))return!1;if(!Array.isArray(b))throw Error("[isEq] third parameter should be an array of keys!");
if(0===b.length)return!0;for(var d in b)if(f=b[d],Array.isArray(a[f])&&Array.isArray(c[f])&&(f=d),a[f]!==c[f])if(g("object"===a[f])&&g("object"===c[f])||Array.isArray(a[f])&&Array.isArray(c[f])){if(!n(a[f],c[f]))return!1}else return!1;return!0}},{}]},{},[1])(1)})}).call(this,"undefined"!==typeof global?global:"undefined"!==typeof self?self:"undefined"!==typeof window?window:{})},{}],3:[function(a,b,h){(function(e){function d(a,c,b){c in a?Object.defineProperty(a,c,{value:b,enumerable:!0,configurable:!0,
writable:!0}):a[c]=b;return a}function m(a){if(Array.isArray(a)){for(var c=0,b=Array(a.length);c<a.length;c++)b[c]=a[c];return b}return Array.from(a)}var c=Object.assign||function(a){for(var c=1;c<arguments.length;c++){var b=arguments[c],g;for(g in b)Object.prototype.hasOwnProperty.call(b,g)&&(a[g]=b[g])}return a},g="function"===typeof Symbol&&"symbol"===_typeof2(Symbol.iterator)?function(a){return"undefined"===typeof a?"undefined":_typeof2(a)}:function(a){return a&&"function"===typeof Symbol&&a.constructor===
Symbol&&a!==Symbol.prototype?"symbol":"undefined"===typeof a?"undefined":_typeof2(a)};(function(a){"object"===("undefined"===typeof h?"undefined":g(h))&&"undefined"!==typeof b?b.exports=a():("undefined"!==typeof window?window:"undefined"!==typeof e?e:"undefined"!==typeof self?self:this).promiseObject=a()})(function(){return function(){function c(b,g,d){function f(e,l){if(!g[e]){if(!b[e]){var m="function"==typeof a&&a;if(!l&&m)return m(e,!0);if(k)return k(e,!0);l=Error("Cannot find module '"+e+"'");
throw l.code="MODULE_NOT_FOUND",l;}l=g[e]={exports:{}};b[e][0].call(l.exports,function(a){return f(b[e][1][a]||a)},l,l.exports,c,b,g,d)}return g[e].exports}for(var k="function"==typeof a&&a,e=0;e<d.length;e++)f(d[e]);return f}return c}()({1:[function(a,c,b){c.exports=a("../index.js")},{"../index.js":2}],2:[function(a,b,e){var f=function(a){return a&&"object"===("undefined"===typeof a?"undefined":g(a))&&a.constructor===Object},l="undefined"!==typeof Symbol?Symbol("SELF"):"[~~//-- SELF --//~~]",k=function(a,
c){return function w(b){return Object.keys(b).reduce(function(g,e){var d=b[e];return d===c?(b[e]=a,[].concat(m(g),[e])):f(d)?[].concat(m(g),m(w(d,c))):g},[])}(a)},h=function(a,c){return Promise.all(a.map(function(a){return Promise.resolve(a).then(c)}))},q=function(a){return Promise.all(Object.keys(a).map(function(c){return Promise.resolve(a[c]).then(function(b){return a[c]=b})})).then(function(c){return a})};b.exports=function(a){var b=!1;return function w(g){return Promise.resolve(g).then(function(g){return Array.isArray(g)?
h(g,function(a){return w(a)}):f(g)?q(Object.keys(g).reduce(function(f,e){return g[e]===a?(b=!0,c({},f,d({},e,l))):c({},f,d({},e,w(g[e])))},{})):g})}(a).then(function(a){b&&k(a,l);return a})}},{}]},{},[1])(1)})}).call(this,"undefined"!==typeof global?global:"undefined"!==typeof self?self:"undefined"!==typeof window?window:{})},{"../index.js":4}],4:[function(a,b,h){var e=function(a){return a&&"object"===("undefined"===typeof a?"undefined":_typeof2(a))&&a.constructor===Object},d="undefined"!==typeof Symbol?
Symbol("SELF"):"[~~//-- SELF --//~~]",m=function(a,c){return function n(b){return Object.keys(b).reduce(function(f,g){var d=b[g];return d===c?(b[g]=a,[].concat(_toConsumableArray2(f),[g])):e(d)?[].concat(_toConsumableArray2(f),_toConsumableArray2(n(d,c))):f},[])}(a)},c=function(a,c){return Promise.all(a.map(function(a){return Promise.resolve(a).then(c)}))},g=function(a){return Promise.all(Object.keys(a).map(function(c){return Promise.resolve(a[c]).then(function(b){return a[c]=b})})).then(function(c){return a})};
b.exports=function(a){var b=!1;return function n(f){return Promise.resolve(f).then(function(f){return Array.isArray(f)?c(f,function(a){return n(a)}):e(f)?g(Object.keys(f).reduce(function(c,g){return f[g]===a?(b=!0,_extends2({},c,_defineProperty2({},g,d))):_extends2({},c,_defineProperty2({},g,n(f[g])))},{})):f})}(a).then(function(a){b&&m(a,d);return a})}},{}],5:[function(a,b,h){},{}],6:[function(a,b,h){function e(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=p(null),
this._eventsCount=0);this._maxListeners=this._maxListeners||void 0}function d(a,c,b,f){var g;if("function"!==typeof b)throw new TypeError('"listener" argument must be a function');if(g=a._events){g.newListener&&(a.emit("newListener",c,b.listener?b.listener:b),g=a._events);var d=g[c]}else g=a._events=p(null),a._eventsCount=0;d?("function"===typeof d?d=g[c]=f?[b,d]:[d,b]:f?d.unshift(b):d.push(b),d.warned||(b=void 0===a._maxListeners?e.defaultMaxListeners:a._maxListeners)&&0<b&&d.length>b&&(d.warned=
!0,b=Error("Possible EventEmitter memory leak detected. "+d.length+' "'+String(c)+'" listeners added. Use emitter.setMaxListeners() to increase limit.'),b.name="MaxListenersExceededWarning",b.emitter=a,b.type=c,b.count=d.length,"object"===("undefined"===typeof console?"undefined":_typeof2(console))&&console.warn&&console.warn("%s: %s",b.name,b.message))):(g[c]=b,++a._eventsCount);return a}function l(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);
case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var a=Array(arguments.length),c=0;c<a.length;++c)a[c]=arguments[c];this.listener.apply(this.target,a)}}function c(a,c,b){a={fired:!1,wrapFn:void 0,target:a,type:c,listener:b};c=q.call(l,a);c.listener=b;return a.wrapFn=c}function g(a,c,b){a=a._events;if(!a)return[];c=a[c];if(!c)return[];
if("function"===typeof c)return b?[c.listener||c]:[c];if(b)for(b=Array(c.length),a=0;a<b.length;++a)b[a]=c[a].listener||c[a];else b=f(c,c.length);return b}function k(a){var c=this._events;if(c){a=c[a];if("function"===typeof a)return 1;if(a)return a.length}return 0}function f(a,c){for(var b=Array(c),g=0;g<c;++g)b[g]=a[g];return b}function m(a){var c=function(){};c.prototype=a;return new c}function r(a){var c=[],b;for(b in a)Object.prototype.hasOwnProperty.call(a,b)&&c.push(b);return b}function n(a){var c=
this;return function(){return c.apply(a,arguments)}}var p=Object.create||m,t=Object.keys||r,q=Function.prototype.bind||n;b.exports=e;e.EventEmitter=e;e.prototype._events=void 0;e.prototype._maxListeners=void 0;var u=10;try{a={};Object.defineProperty&&Object.defineProperty(a,"x",{value:0});var v=0===a.x}catch(x){v=!1}v?Object.defineProperty(e,"defaultMaxListeners",{enumerable:!0,get:function(){return u},set:function(a){if("number"!==typeof a||0>a||a!==a)throw new TypeError('"defaultMaxListeners" must be a positive number');
!0,b=Error("Possible EventEmitter memory leak detected. "+d.length+' "'+String(c)+'" listeners added. Use emitter.setMaxListeners() to increase limit.'),b.name="MaxListenersExceededWarning",b.emitter=a,b.type=c,b.count=d.length,"object"===("undefined"===typeof console?"undefined":_typeof2(console))&&console.warn&&console.warn("%s: %s",b.name,b.message))):(g[c]=b,++a._eventsCount);return a}function m(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);
case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var a=Array(arguments.length),c=0;c<a.length;++c)a[c]=arguments[c];this.listener.apply(this.target,a)}}function c(a,c,b){a={fired:!1,wrapFn:void 0,target:a,type:c,listener:b};c=q.call(m,a);c.listener=b;return a.wrapFn=c}function g(a,c,b){a=a._events;if(!a)return[];c=a[c];if(!c)return[];
if("function"===typeof c)return b?[c.listener||c]:[c];if(b)for(b=Array(c.length),a=0;a<b.length;++a)b[a]=c[a].listener||c[a];else b=f(c,c.length);return b}function l(a){var c=this._events;if(c){a=c[a];if("function"===typeof a)return 1;if(a)return a.length}return 0}function f(a,c){for(var b=Array(c),f=0;f<c;++f)b[f]=a[f];return b}function k(a){var c=function(){};c.prototype=a;return new c}function r(a){var c=[],b;for(b in a)Object.prototype.hasOwnProperty.call(a,b)&&c.push(b);return b}function n(a){var c=
this;return function(){return c.apply(a,arguments)}}var p=Object.create||k,t=Object.keys||r,q=Function.prototype.bind||n;b.exports=e;e.EventEmitter=e;e.prototype._events=void 0;e.prototype._maxListeners=void 0;var u=10;try{a={};Object.defineProperty&&Object.defineProperty(a,"x",{value:0});var v=0===a.x}catch(x){v=!1}v?Object.defineProperty(e,"defaultMaxListeners",{enumerable:!0,get:function(){return u},set:function(a){if("number"!==typeof a||0>a||a!==a)throw new TypeError('"defaultMaxListeners" must be a positive number');
u=a}}):e.defaultMaxListeners=u;e.prototype.setMaxListeners=function(a){if("number"!==typeof a||0>a||isNaN(a))throw new TypeError('"n" argument must be a positive number');this._maxListeners=a;return this};e.prototype.getMaxListeners=function(){return void 0===this._maxListeners?e.defaultMaxListeners:this._maxListeners};e.prototype.emit=function(a){var c,b,g;var d="error"===a;if(g=this._events)d=d&&null==g.error;else if(!d)return!1;if(d){1<arguments.length&&(c=arguments[1]);if(c instanceof Error)throw c;
g=Error('Unhandled "error" event. ('+c+")");g.context=c;throw g;}c=g[a];if(!c)return!1;g="function"===typeof c;var e=arguments.length;switch(e){case 1:if(g)c.call(this);else for(g=c.length,c=f(c,g),d=0;d<g;++d)c[d].call(this);break;case 2:d=arguments[1];if(g)c.call(this,d);else for(g=c.length,c=f(c,g),e=0;e<g;++e)c[e].call(this,d);break;case 3:d=arguments[1];e=arguments[2];if(g)c.call(this,d,e);else for(g=c.length,c=f(c,g),b=0;b<g;++b)c[b].call(this,d,e);break;case 4:d=arguments[1];e=arguments[2];
b=arguments[3];if(g)c.call(this,d,e,b);else{g=c.length;c=f(c,g);for(var k=0;k<g;++k)c[k].call(this,d,e,b)}break;default:d=Array(e-1);for(b=1;b<e;b++)d[b-1]=arguments[b];if(g)c.apply(this,d);else for(g=c.length,c=f(c,g),e=0;e<g;++e)c[e].apply(this,d)}return!0};e.prototype.addListener=function(a,c){return d(this,a,c,!1)};e.prototype.on=e.prototype.addListener;e.prototype.prependListener=function(a,c){return d(this,a,c,!0)};e.prototype.once=function(a,b){if("function"!==typeof b)throw new TypeError('"listener" argument must be a function');
this.on(a,c(this,a,b));return this};e.prototype.prependOnceListener=function(a,b){if("function"!==typeof b)throw new TypeError('"listener" argument must be a function');this.prependListener(a,c(this,a,b));return this};e.prototype.removeListener=function(a,c){var b;if("function"!==typeof c)throw new TypeError('"listener" argument must be a function');var g=this._events;if(!g)return this;var f=g[a];if(!f)return this;if(f===c||f.listener===c)0===--this._eventsCount?this._events=p(null):(delete g[a],
g.removeListener&&this.emit("removeListener",a,f.listener||c));else if("function"!==typeof f){var d=-1;for(b=f.length-1;0<=b;b--)if(f[b]===c||f[b].listener===c){var e=f[b].listener;d=b;break}if(0>d)return this;if(0===d)f.shift();else{b=d+1;for(var k=f.length;b<k;d+=1,b+=1)f[d]=f[b];f.pop()}1===f.length&&(g[a]=f[0]);g.removeListener&&this.emit("removeListener",a,e||c)}return this};e.prototype.removeAllListeners=function(a){var c=this._events;if(!c)return this;if(!c.removeListener)return 0===arguments.length?
(this._events=p(null),this._eventsCount=0):c[a]&&(0===--this._eventsCount?this._events=p(null):delete c[a]),this;if(0===arguments.length){var b=t(c);for(c=0;c<b.length;++c){var g=b[c];"removeListener"!==g&&this.removeAllListeners(g)}this.removeAllListeners("removeListener");this._events=p(null);this._eventsCount=0;return this}b=c[a];if("function"===typeof b)this.removeListener(a,b);else if(b)for(c=b.length-1;0<=c;c--)this.removeListener(a,b[c]);return this};e.prototype.listeners=function(a){return g(this,
a,!0)};e.prototype.rawListeners=function(a){return g(this,a,!1)};e.listenerCount=function(a,c){return"function"===typeof a.listenerCount?a.listenerCount(c):k.call(a,c)};e.prototype.listenerCount=k;e.prototype.eventNames=function(){return 0<this._eventsCount?Reflect.ownKeys(this._events):[]}},{}],7:[function(a,b,h){function e(a,b){var c=[],g=[];null==b&&(b=function(a,b){return c[0]===b?"[Circular ~]":"[Circular ~."+g.slice(0,c.indexOf(b)).join(".")+"]"});return function(d,f){if(0<c.length){var e=c.indexOf(this);
~e?c.splice(e+1):c.push(this);~e?g.splice(e,Infinity,d):g.push(d);~c.indexOf(f)&&(f=b.call(this,d,f))}else c.push(f);return null==a?f:a.call(this,d,f)}}h=b.exports=function(a,b,c,g){return JSON.stringify(a,e(b,g),c)};h.getSerialize=e},{}],8:[function(a,b,h){function e(){throw Error("setTimeout has not been defined");}function d(){throw Error("clearTimeout has not been defined");}function l(a){if(r===setTimeout)return setTimeout(a,0);if((r===e||!r)&&setTimeout)return r=setTimeout,setTimeout(a,0);try{return r(a,
0)}catch(x){try{return r.call(null,a,0)}catch(y){return r.call(this,a,0)}}}function c(a){if(n===clearTimeout)return clearTimeout(a);if((n===d||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(a);try{return n(a)}catch(x){try{return n.call(null,a)}catch(y){return n.call(this,a)}}}function g(){t&&q&&(t=!1,q.length?p=q.concat(p):u=-1,p.length&&k())}function k(){if(!t){var a=l(g);t=!0;for(var b=p.length;b;){q=p;for(p=[];++u<b;)q&&q[u].run();u=-1;b=p.length}q=null;t=!1;c(a)}}function f(a,c){this.fun=
a;this.array=c}function m(){}a=b.exports={};try{var r="function"===typeof setTimeout?setTimeout:e}catch(v){r=e}try{var n="function"===typeof clearTimeout?clearTimeout:d}catch(v){n=d}var p=[],t=!1,q,u=-1;a.nextTick=function(a){var c=Array(arguments.length-1);if(1<arguments.length)for(var b=1;b<arguments.length;b++)c[b-1]=arguments[b];p.push(new f(a,c));1!==p.length||t||l(k)};f.prototype.run=function(){this.fun.apply(null,this.array)};a.title="browser";a.browser=!0;a.env={};a.argv=[];a.version="";a.versions=
{};a.on=m;a.addListener=m;a.once=m;a.off=m;a.removeListener=m;a.removeAllListeners=m;a.emit=m;a.prependListener=m;a.prependOnceListener=m;a.listeners=function(a){return[]};a.binding=function(a){throw Error("process.binding is not supported");};a.cwd=function(){return"/"};a.chdir=function(a){throw Error("process.chdir is not supported");};a.umask=function(){return 0}},{}],9:[function(a,b,h){(function(e){var d=a("./util").arrayOrPush,l=a("./lib/caller"),c=a("./lib/emitter"),g=a("./reporters"),k=a("./lib/testrunner"),
f=a("./lib/expect"),m=a("./util/symbols"),h=function(){function a(c){var b,g;_classCallCheck(this,a);this.name=c;this.__suite__={tests:[],beforeHooks:(b={},_defineProperty2(b,m.Start,[]),_defineProperty2(b,m.End,[]),_defineProperty2(b,"*",[]),b),afterHooks:(g={},_defineProperty2(g,m.Start,[]),_defineProperty2(g,m.End,[]),_defineProperty2(g,"*",[]),g)}}_createClass(a,[{key:"test",value:function(a,c){if(this.__suite__.tests.find(function(c){return c.description===a}))throw Error("Test '"+a+"' already exists!");
this.__suite__.tests.push({description:a,type:"test",run:function(a){return l(c,a)}});return this}},{key:"before",value:function(a,c,b){d(this.__suite__.beforeHooks,a,{description:a,label:b,type:"hook",run:function(a){return l(c,a)}});return this}},{key:"after",value:function(a,c,b){d(this.__suite__.afterHooks,a,{description:a,label:b,type:"hook",run:function(a){return l(c,a)}});return this}},{key:"run",value:function(){var a=this,b=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};if(!0===
b.reporter)g.default(c,b);else if("function"===typeof b.reporter)b.reporter(c,b);else if(g[b.reporter])g[b.reporter](c,b);c.emit("start");return k(this,b).then(function(f){var d;f.count=f.length;f.success=f.filter(function(a){return"ok"===a.status});f.failures=f.filter(function(a){return"notOk"===a.status});f.skipped=f.filter(function(a){return"skip"===a.status});f.successPercent=Math.floor(f.success.length/f.length*100);f.name=a.name;100!==f.successPercent&&"undefined"!==typeof e&&(e.exitCode=1);
c.emit("test end",f);c.emit("end",f);return b.request?(d={},_defineProperty2(d,b.request,g[b.request].convert(f)),_defineProperty2(d,"json",f),d):f})}}]);return a}();b.exports=h;b.exports.expect=f;b.exports.expectMany=f.expectMany;b.exports.Start=m.Start;b.exports.End=m.End;b.exports.Gunner=b.exports}).call(this,a("_process"))},{"./lib/caller":13,"./lib/emitter":14,"./lib/expect":15,"./lib/testrunner":16,"./reporters":18,"./util":21,"./util/symbols":22,_process:8}],10:[function(a,b,h){var e=a("../util").isPromise,
d=function(a){for(var c=arguments.length,b=Array(1<c?c-1:0),d=1;d<c;d++)b[d-1]=arguments[d];return Promise.reject(a?a.apply(void 0,b):"")};b.exports=function(a,c){var b=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},k=_toArray(c),f=k[0],m=k.slice(1);f=b.skipStatement?function(){return b.skipStatement}:f;return e(a)?a.catch(function(){return d.apply(void 0,[f].concat(_toConsumableArray2(m)))}):a?Promise.resolve():d.apply(void 0,[f].concat(_toConsumableArray2(m)))}},{"../util":21}],11:[function(a,
b,h){var e=a("@codefeathers/iseq"),d=a("../util"),l=d.taggedStringify;b.exports.done=[function(){return!0},function(){return null}];b.exports.fail=[function(){return!1},function(a,b){return b}];b.exports.exists=[function(a){return"undefined"!==typeof a},function(){return"Value is undefined"}];b.exports.isArray=[function(a){return Array.isArray(a)},function(a){return l(_templateObject,a)}];b.exports.isObject=[function(a){return"object"===("undefined"===typeof a?"undefined":_typeof2(a))&&null!==a},
function(a){return l(_templateObject2,a)}];b.exports.hasLength=[function(a,b){return a.length===b},function(a,b){return l(_templateObject3,a,b)}];b.exports.equals=[function(a,b){return a===b},function(a,b){return l(_templateObject4,a,b)}];b.exports.deepEquals=[function(a,b){return e(a,b)},function(a,b){return l(_templateObject5,a,b)}];b.exports.contains=[function(a,b){return e(a,b,Object.keys(b))},function(a,b){return l(_templateObject6,a,b)}];b.exports.isTrue=[function(a){return!0===a},function(a){return l(_templateObject7,
a)}];b.exports.isFalse=[function(a){return!1===a},function(a){return l(_templateObject8,a)}];b.exports.hasProp=[function(a,b){return a.hasOwnProperty(b)},function(a,b){return l(_templateObject9,a,b)}];b.exports.hasPair=[function(a){for(var b=arguments.length,c=Array(1<b?b-1:0),f=1;f<b;f++)c[f-1]=arguments[f];return e(a[c[0]],c[1])},function(a){for(var b=arguments.length,c=Array(1<b?b-1:0),f=1;f<b;f++)c[f-1]=arguments[f];return l(_templateObject10,c,a)}];b.exports.isPromise=[function(a){return d.isPromise(a)},
function(a){return l(_templateObject11,a)},{shouldCatch:!0}];b.exports.resolvesTo=[function(a,b){return d.isPromise(a)?a.then(function(a){return a===b?Promise.resolve():Promise.reject()}):Promise.reject(a+" was not a Promise")},function(a,b){return l(_templateObject12,a,b)}];b.exports.isType=[function(a,b){return"nil"===b&&("null"===a||"undefined"===a)||("undefined"===typeof a?"undefined":_typeof2(a))===b||Array.isArray(a)&&"array"===b&&null===a&&"object"!==b},function(a,b){return l(_templateObject13,
a,b)}];b.exports.greaterThan=[function(a,b){return a>b},function(a,b){return l(_templateObject14,a,b)}];b.exports.lessThan=[function(a,b){return a<b},function(a,b){return l(_templateObject15,a,b)}];b.exports.gte=[function(a,b){return a>=b},function(a,b){return l(_templateObject16,a,b)}];b.exports.lte=[function(a,b){return a<=b},function(a,b){return l(_templateObject17,a,b)}];b.exports.success=b.exports.done;b.exports.succeed=b.exports.done;b.exports.failure=b.exports.fail;b.exports.equal=b.exports.equals;
a,!0)};e.prototype.rawListeners=function(a){return g(this,a,!1)};e.listenerCount=function(a,c){return"function"===typeof a.listenerCount?a.listenerCount(c):l.call(a,c)};e.prototype.listenerCount=l;e.prototype.eventNames=function(){return 0<this._eventsCount?Reflect.ownKeys(this._events):[]}},{}],7:[function(a,b,h){function e(a,b){var c=[],g=[];null==b&&(b=function(a,b){return c[0]===b?"[Circular ~]":"[Circular ~."+g.slice(0,c.indexOf(b)).join(".")+"]"});return function(d,f){if(0<c.length){var e=c.indexOf(this);
~e?c.splice(e+1):c.push(this);~e?g.splice(e,Infinity,d):g.push(d);~c.indexOf(f)&&(f=b.call(this,d,f))}else c.push(f);return null==a?f:a.call(this,d,f)}}h=b.exports=function(a,b,c,g){return JSON.stringify(a,e(b,g),c)};h.getSerialize=e},{}],8:[function(a,b,h){function e(){throw Error("setTimeout has not been defined");}function d(){throw Error("clearTimeout has not been defined");}function m(a){if(r===setTimeout)return setTimeout(a,0);if((r===e||!r)&&setTimeout)return r=setTimeout,setTimeout(a,0);try{return r(a,
0)}catch(x){try{return r.call(null,a,0)}catch(y){return r.call(this,a,0)}}}function c(a){if(n===clearTimeout)return clearTimeout(a);if((n===d||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(a);try{return n(a)}catch(x){try{return n.call(null,a)}catch(y){return n.call(this,a)}}}function g(){t&&q&&(t=!1,q.length?p=q.concat(p):u=-1,p.length&&l())}function l(){if(!t){var a=m(g);t=!0;for(var b=p.length;b;){q=p;for(p=[];++u<b;)q&&q[u].run();u=-1;b=p.length}q=null;t=!1;c(a)}}function f(a,c){this.fun=
a;this.array=c}function k(){}a=b.exports={};try{var r="function"===typeof setTimeout?setTimeout:e}catch(v){r=e}try{var n="function"===typeof clearTimeout?clearTimeout:d}catch(v){n=d}var p=[],t=!1,q,u=-1;a.nextTick=function(a){var c=Array(arguments.length-1);if(1<arguments.length)for(var b=1;b<arguments.length;b++)c[b-1]=arguments[b];p.push(new f(a,c));1!==p.length||t||m(l)};f.prototype.run=function(){this.fun.apply(null,this.array)};a.title="browser";a.browser=!0;a.env={};a.argv=[];a.version="";a.versions=
{};a.on=k;a.addListener=k;a.once=k;a.off=k;a.removeListener=k;a.removeAllListeners=k;a.emit=k;a.prependListener=k;a.prependOnceListener=k;a.listeners=function(a){return[]};a.binding=function(a){throw Error("process.binding is not supported");};a.cwd=function(){return"/"};a.chdir=function(a){throw Error("process.chdir is not supported");};a.umask=function(){return 0}},{}],9:[function(a,b,h){(function(e){var d=a("./util").arrayOrPush,m=a("./lib/caller"),c=a("./lib/emitter"),g=a("./reporters"),l=a("./lib/testrunner"),
f=a("./lib/expect"),k=a("./util/symbols"),h=function(){function a(c){var b,g;_classCallCheck(this,a);this.name=c;this.__suite__={tests:[],beforeHooks:(b={},_defineProperty2(b,k.Start,[]),_defineProperty2(b,k.End,[]),_defineProperty2(b,"*",[]),b),afterHooks:(g={},_defineProperty2(g,k.Start,[]),_defineProperty2(g,k.End,[]),_defineProperty2(g,"*",[]),g)}}_createClass(a,[{key:"test",value:function(a,c){if(this.__suite__.tests.find(function(c){return c.description===a}))throw Error("Test '"+a+"' already exists!");
this.__suite__.tests.push({description:a,type:"test",run:function(a){return m(c,a)}});return this}},{key:"before",value:function(a,c,b){d(this.__suite__.beforeHooks,a,{description:a,label:b,type:"hook",run:function(a){return m(c,a)}});return this}},{key:"after",value:function(a,c,b){d(this.__suite__.afterHooks,a,{description:a,label:b,type:"hook",run:function(a){return m(c,a)}});return this}},{key:"run",value:function(){var a=this,b=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};if(!0===
b.reporter)g.default(c,b);else if("function"===typeof b.reporter)b.reporter(c,b);else if(g[b.reporter])g[b.reporter](c,b);c.emit("start");return l(this,b).then(function(f){var d;f.count=f.length;f.success=f.filter(function(a){return"ok"===a.status});f.failures=f.filter(function(a){return"notOk"===a.status});f.skipped=f.filter(function(a){return"skip"===a.status});f.successPercent=Math.floor(f.success.length/f.length*100);f.name=a.name;100!==f.successPercent&&"undefined"!==typeof e&&(e.exitCode=1);
c.emit("test end",f);c.emit("end",f);return b.request?(d={},_defineProperty2(d,b.request,g[b.request].convert(f)),_defineProperty2(d,"json",f),d):f})}}]);return a}();b.exports=h;b.exports.expect=f;b.exports.expectMany=f.expectMany;b.exports.Start=k.Start;b.exports.End=k.End;b.exports.Gunner=b.exports}).call(this,a("_process"))},{"./lib/caller":13,"./lib/emitter":14,"./lib/expect":15,"./lib/testrunner":16,"./reporters":18,"./util":21,"./util/symbols":22,_process:8}],10:[function(a,b,h){var e=a("../util").isPromise,
d=function(a){for(var c=arguments.length,b=Array(1<c?c-1:0),d=1;d<c;d++)b[d-1]=arguments[d];return Promise.reject(a?a.apply(void 0,b):"")};b.exports=function(a,c){var b=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},l=_toArray(c),f=l[0],k=l.slice(1);f=b.skipStatement?function(){return b.skipStatement}:f;return e(a)?a.catch(function(){return d.apply(void 0,[f].concat(_toConsumableArray2(k)))}):a?Promise.resolve():d.apply(void 0,[f].concat(_toConsumableArray2(k)))}},{"../util":21}],11:[function(a,
b,h){var e=a("@codefeathers/iseq"),d=a("../util"),m=d.taggedStringify;b.exports.done=[function(){return!0},function(){return null}];b.exports.fail=[function(){return!1},function(a,b){return b}];b.exports.exists=[function(a){return"undefined"!==typeof a},function(){return"Value is undefined"}];b.exports.isArray=[function(a){return Array.isArray(a)},function(a){return m(_templateObject,a)}];b.exports.isObject=[function(a){return"object"===("undefined"===typeof a?"undefined":_typeof2(a))&&null!==a},
function(a){return m(_templateObject2,a)}];b.exports.hasLength=[function(a,b){return a.length===b},function(a,b){return m(_templateObject3,a,b)}];b.exports.equals=[function(a,b){return a===b},function(a,b){return m(_templateObject4,a,b)}];b.exports.deepEquals=[function(a,b){return e(a,b)},function(a,b){return m(_templateObject5,a,b)}];b.exports.contains=[function(a,b){return e(a,b,Object.keys(b))},function(a,b){return m(_templateObject6,a,b)}];b.exports.isTrue=[function(a){return!0===a},function(a){return m(_templateObject7,
a)}];b.exports.isFalse=[function(a){return!1===a},function(a){return m(_templateObject8,a)}];b.exports.hasProp=[function(a,b){return a.hasOwnProperty(b)},function(a,b){return m(_templateObject9,a,b)}];b.exports.hasPair=[function(a){for(var c=arguments.length,b=Array(1<c?c-1:0),f=1;f<c;f++)b[f-1]=arguments[f];return e(a[b[0]],b[1])},function(a){for(var c=arguments.length,b=Array(1<c?c-1:0),f=1;f<c;f++)b[f-1]=arguments[f];return m(_templateObject10,b,a)}];b.exports.isPromise=[function(a){return d.isPromise(a)},
function(a){return m(_templateObject11,a)},{shouldCatch:!0}];b.exports.resolvesTo=[function(a,b){return d.isPromise(a)?a.then(function(a){return a===b?Promise.resolve():Promise.reject()}):Promise.reject(a+" was not a Promise")},function(a,b){return m(_templateObject12,a,b)}];b.exports.isType=[function(a,b){return"nil"===b&&("null"===a||"undefined"===a)||("undefined"===typeof a?"undefined":_typeof2(a))===b||Array.isArray(a)&&"array"===b&&null===a&&"object"!==b},function(a,b){return m(_templateObject13,
a,b)}];b.exports.greaterThan=[function(a,b){return a>b},function(a,b){return m(_templateObject14,a,b)}];b.exports.lessThan=[function(a,b){return a<b},function(a,b){return m(_templateObject15,a,b)}];b.exports.gte=[function(a,b){return a>=b},function(a,b){return m(_templateObject16,a,b)}];b.exports.lte=[function(a,b){return a<=b},function(a,b){return m(_templateObject17,a,b)}];b.exports.success=b.exports.done;b.exports.succeed=b.exports.done;b.exports.failure=b.exports.fail;b.exports.equal=b.exports.equals;
b.exports.deepEqual=b.exports.deepEquals;b.exports.match=b.exports.deepEquals;b.exports.greaterThanOrEqualTo=b.exports.gte;b.exports.lessThanOrEqualTo=b.exports.lte},{"../util":21,"@codefeathers/iseq":2}],12:[function(a,b,h){a("../gunner");var e=a("../util/symbols"),d=function(a){return function(b){return{type:a,unit:b}}};b.exports=function(a){var b=[];Array.prototype.push.apply(b,a.__suite__.beforeHooks[e.Start].map(d("@start")));b.push.apply(a.__suite__.afterHooks[e.Start].map(d("@start")));a.__suite__.tests.forEach(function(c){return Array.prototype.push.apply(b,
a.__suite__.beforeHooks["*"].map(d("@every"))),Array.prototype.push.apply(b,(a.__suite__.beforeHooks[c.description]||[]).map(d("@this"))),b.push(d("@test")(c)),Array.prototype.push.apply(b,(a.__suite__.afterHooks[c.description]||[]).map(d("@afterTest"))),Array.prototype.push.apply(b,a.__suite__.afterHooks["*"].map(d("@afterEvery")))});Array.prototype.push.apply(b,a.__suite__.beforeHooks[e.End].map(d("@beforeend")));Array.prototype.push.apply(b,a.__suite__.afterHooks[e.End].map(d("@end")));return b}},
{"../gunner":9,"../util/symbols":22}],13:[function(a,b,h){var e=a("perf_hooks").performance,d=a("../util").isPromise;b.exports=function(a,b){var c=0,k=0,f=void 0,m=void 0,h=void 0;try{c=e.now(),f=a(b),k=e.now()}catch(n){k=e.now(),h=!0,m=n}return d(f)?f.then(function(a){return{duration:e.now()-c,status:"ok",resolve:a,promise:!0}}).catch(function(a){return{duration:e.now()-c,status:"notOk",rejection:a,promise:!0}}):Promise.resolve(_extends2({duration:k-c,status:h?"notOk":"ok"},!h&&{value:f},h&&{error:m},
{promise:!1}))}},{"../util":21,perf_hooks:5}],14:[function(a,b,h){a=function(a){function b(){_classCallCheck(this,b);return _possibleConstructorReturn(this,(b.__proto__||Object.getPrototypeOf(b)).apply(this,arguments))}_inherits(b,a);return b}(a("events"));b.exports=new a},{events:6}],15:[function(a,b,h){h=a("../util");var e=h.liftPromise,d=h.lowerCaseFirstLetter,l=a("./assertionsLibrary"),c=a("./assertPromise"),g=function(a,b){var f=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};return function(d){return function(){for(var g=
arguments.length,m=Array(g),k=0;k<g;k++)m[k]=arguments[k];return e(function(f){return c(a.apply(void 0,[d].concat(m)),[b,f].concat(m))},d).catch(function(e){return f.shouldCatch?c(a.apply(void 0,[d].concat(m)),[b,e].concat(m),{skipStatement:e}):Promise.reject(e)})}}},k=Object.keys(l).reduce(function(a,b){var c=_slicedToArray(l[b],3);a[b]=g(c[0],c[1],c[2]);return a},{});b.exports=function(a,b){return new Proxy({},{get:function(c,f){var e=b?a.apply(void 0,_toConsumableArray2(b)):a;if(k.hasOwnProperty(f))return function(){return k[f](e).apply(void 0,
arguments)};if("not"===f.slice(0,3))return function(){return k[d(f.slice(3))](e).apply(void 0,arguments).then(Promise.reject,Promise.resolve)};throw Error("Unknown assertion method",f);}})};b.exports.expectMany=function(){for(var a=arguments.length,b=Array(a),c=0;c<a;c++)b[c]=arguments[c];return Promise.all(b)}},{"../util":21,"./assertPromise":10,"./assertionsLibrary":11}],16:[function(a,b,h){a("../gunner");Promise.object=a("@codefeathers/promise.object");var e=a("perf_hooks").performance;h=a("../util");
var d=h.last,l=h.pipe,c=h.pick,g=h.assignToObject,k=a("./buildTestQueue"),f=function(a,b){var c=a.findIndex(function(a){return"@start"===a.type}),f=a.findIndex(function(a){return"@every"===a.type}),d=a.findIndex(function(a){return a.description===b.description});return-1!==c&&"A start hook failed\n"+a[c].error||-1!==f&&"An every hook failed\n"+a[f].error||-1!==d&&"A before test hook failed\n"+a[d].error},m=function(a){return a.reduce(function(b,c){return Promise.resolve(b).then(function(b){return Promise.all([d(b.results),
Promise.object(b.state)]).then(function(a){a=_slicedToArray(a,2)[1];return[f(b.skip,c.unit),a]}).then(function(a){var b=_slicedToArray(a,2);a=b[0];b=b[1];return a?{status:"skip",description:a}:c.unit.run(b)}).then(function(f){var d=f.status,e=f.duration;if("@test"===c.type)e=_extends2({status:d,duration:e,description:c.unit.description},("notOk"===d||"skip"===d)&&{reason:f.error||f.rejection||f.description}),b.results.push(e);else{e=c.unit.label||a.filter(function(a){return a.type===c.type}).filter(function(a){return a.unit.description===
c.unit.description}).length;var k="ok"===d?f.promise?f.resolve:f.value:null;e&&k&&g(b.state,c.type)(e,k)}"notOk"===d&&b.skip.push({type:c.type,description:c.unit.description,error:f.promise?f.rejection:f.error});return b})})},{results:[],state:{},skip:[]})};b.exports=function(a){var b=e.now();return Promise.object(l(k,m,c("results"))(a)).then(function(a){a.duration=e.now()-b;return a})}},{"../gunner":9,"../util":21,"./buildTestQueue":12,"@codefeathers/promise.object":3,perf_hooks:5}],17:[function(a,
{"../gunner":9,"../util/symbols":22}],13:[function(a,b,h){var e=a("../util").isPromise;b.exports=function(a,b){var c=0,d=0,l=void 0,f=void 0,k=void 0;try{c=Date.now(),l=a(b),d=Date.now()}catch(r){d=Date.now(),k=!0,f=r}return e(l)?l.then(function(a){return{duration:Date.now()-c,status:"ok",resolve:a,promise:!0}}).catch(function(a){return{duration:Date.now()-c,status:"notOk",rejection:a,promise:!0}}):Promise.resolve(_extends2({duration:d-c,status:k?"notOk":"ok"},!k&&{value:l},k&&{error:f},{promise:!1}))}},
{"../util":21}],14:[function(a,b,h){a=function(a){function b(){_classCallCheck(this,b);return _possibleConstructorReturn(this,(b.__proto__||Object.getPrototypeOf(b)).apply(this,arguments))}_inherits(b,a);return b}(a("events"));b.exports=new a},{events:6}],15:[function(a,b,h){h=a("../util");var e=h.liftPromise,d=h.lowerCaseFirstLetter,m=a("./assertionsLibrary"),c=a("./assertPromise"),g=function(a,b){var f=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};return function(d){return function(){for(var g=
arguments.length,k=Array(g),l=0;l<g;l++)k[l]=arguments[l];return e(function(f){return c(a.apply(void 0,[d].concat(k)),[b,f].concat(k))},d).catch(function(e){return f.shouldCatch?c(a.apply(void 0,[d].concat(k)),[b,e].concat(k),{skipStatement:e}):Promise.reject(e)})}}},l=Object.keys(m).reduce(function(a,b){var c=_slicedToArray(m[b],3);a[b]=g(c[0],c[1],c[2]);return a},{});b.exports=function(a,b){return new Proxy({},{get:function(c,f){var e=b?a.apply(void 0,_toConsumableArray2(b)):a;if(l.hasOwnProperty(f))return function(){return l[f](e).apply(void 0,
arguments)};if("not"===f.slice(0,3))return function(){return l[d(f.slice(3))](e).apply(void 0,arguments).then(Promise.reject,Promise.resolve)};throw Error("Unknown assertion method",f);}})};b.exports.expectMany=function(){for(var a=arguments.length,b=Array(a),c=0;c<a;c++)b[c]=arguments[c];return Promise.all(b)}},{"../util":21,"./assertPromise":10,"./assertionsLibrary":11}],16:[function(a,b,h){a("../gunner");Promise.object=a("@codefeathers/promise.object");a("perf_hooks");h=a("../util");var e=h.last,
d=h.pipe,m=h.pick,c=h.assignToObject,g=a("./buildTestQueue"),l=function(a,b){var c=a.findIndex(function(a){return"@start"===a.type}),f=a.findIndex(function(a){return"@every"===a.type}),d=a.findIndex(function(a){return a.description===b.description});return-1!==c&&"A start hook failed\n"+a[c].error||-1!==f&&"An every hook failed\n"+a[f].error||-1!==d&&"A before test hook failed\n"+a[d].error},f=function(a){return a.reduce(function(b,f){return Promise.resolve(b).then(function(b){return Promise.all([e(b.results),
Promise.object(b.state)]).then(function(a){a=_slicedToArray(a,2)[1];return[l(b.skip,f.unit),a]}).then(function(a){var b=_slicedToArray(a,2);a=b[0];b=b[1];return a?{status:"skip",description:a}:f.unit.run(b)}).then(function(d){var e=d.status,g=d.duration;if("@test"===f.type)g=_extends2({status:e,duration:g,description:f.unit.description},("notOk"===e||"skip"===e)&&{reason:d.error||d.rejection||d.description}),b.results.push(g);else{g=f.unit.label||a.filter(function(a){return a.type===f.type}).filter(function(a){return a.unit.description===
f.unit.description}).length;var k="ok"===e?d.promise?d.resolve:d.value:null;g&&k&&c(b.state,f.type)(g,k)}"notOk"===e&&b.skip.push({type:f.type,description:f.unit.description,error:d.promise?d.rejection:d.error});return b})})},{results:[],state:{},skip:[]})};b.exports=function(a){var b=Date.now();return Promise.object(d(g,f,m("results"))(a)).then(function(a){a.duration=Date.now()-b;return a})}},{"../gunner":9,"../util":21,"./buildTestQueue":12,"@codefeathers/promise.object":3,perf_hooks:5}],17:[function(a,
b,h){var e={ok:["ok","\u2705"],notOk:["notOk","\u274c"],skip:["skip","\u26a0\ufe0f"]};b.exports=function(a,b){a.on("start",function(){return console.log("Started tests")});a.on("test end",function(a){a.forEach(function(a){var c=e[a.status];console.log(">",c[0],c[1],a.description);b.trace&&a.reason&&console.log("\n---\n\n",a.reason,"\n\n---\n")})});a.on("end",function(a){console.log(a.success.length,"tests of",a.length,"passed");console.log("Success ratio:",a.successPercent,"%")})};b.exports.convert=
function(a){return a}},{}],18:[function(a,b,h){b.exports={default:a("./default"),tap:a("./tap"),xunit:a("./xunit")}},{"./default":17,"./tap":19,"./xunit":20}],19:[function(a,b,h){var e={ok:"ok",notOk:"not ok",skip:"skip"},d=function(a,b){return"\nTAP version 13\n"+(a.length?"1":0)+".."+a.length+"\n"+a.map(function(a,c){var f=b.trace&&a.reason&&(a.reason.stack?a.reason.stack:a.reason)||"";return e[a.status]+" "+(c+1)+" - "+a.description+(f&&"\n ---\n message: |\n "+f+"\n ---\n")}).join("\n")+
"\n"};b.exports=function(a,b){a.on("end",function(a){return console.log(d(a,b))})};b.exports.convert=d},{}],20:[function(a,b,h){var e=function(a,b,d,e){d=d?"/>":">";var c=[],g=void 0;Object.keys(b).forEach(function(a){Object.prototype.hasOwnProperty.call(b,a)&&c.push(a+'="'+b[a]+'"')});g="<"+a+(c.length?" "+c.join(" "):"")+d;e&&(g+=e+"</"+a+d);return new String(g)},d=function(a){return'<?xml version="1.0"?>'+e("testsuites",{},!1,e("testsuite",{name:a.name,tests:a.count,success:a.success.length,failures:a.failures.length,
skipped:a.skipped.length,timestamp:(new Date).toUTCString(),time:a.duration/1E3||0},!1,a.reduce(function(a,b){var c="ok"===b.status,f="ok"!==b.status&&("skip"===b.status?e("skipped",{},!0):e("failure",{},!b.reason,b.reason?b.reason:""));return a+=e("testcase",{name:b.description,time:b.duration/1E3||0},c,f||"")},"")))};b.exports=function(a){a.on("end",function(a){console.log(d(a))})};b.exports.convert=d},{}],21:[function(a,b,h){var e=a("json-stringify-safe"),d=function(a){return a&&"object"===("undefined"===
typeof a?"undefined":_typeof2(a))},l=function(a){return d(a)?a.stack||e(a):a},c=function(a){return a&&"function"===typeof a.then},g=function(a,b){return c(b)?b.then(a):a(b)};b.exports={isObject:d,isPromise:c,liftPromise:g,path:function(a){return function(b){return b.reduce(function(a,b){return a&&a[b]},a)}},pick:function(a){return function(b){return b[a]}},pipe:function(){for(var a=arguments.length,b=Array(a),c=0;c<a;c++)b[c]=arguments[c];return function(a){return b.reduce(function(a,b){return g(b,
a)},a)}},reduce:function(a,b){return function(c){return c.reduce(a,b)}},flatten:function(a){return[].concat.apply([],a)},deepFlatten:function m(a){var b;return(b=[]).concat.apply(b,_toConsumableArray2(a.map(function(a){return Array.isArray(a)?m(a):a})))},map:function(a){return function(b){return b.map(a)}},filter:function(a){return function(b){return b.filter(a)}},identity:function(a){return a},wrapWith:function(a){return function(b){return _defineProperty2({},a,b)}},unwrapFrom:function(a){return function(b){return b[a]}},
promiseAll:function(a){return Promise.all(a)},partial:function(a){for(var b=arguments.length,c=Array(1<b?b-1:0),d=1;d<b;d++)c[d-1]=arguments[d];return function(){for(var b=arguments.length,d=Array(b),f=0;f<b;f++)d[f]=arguments[f];return a.apply(void 0,c.concat(d))}},isIn:function(a,b){return-1!==a.indexOf(b)},containsPath:function(a,b){return a.some(function(a){return b.match(new RegExp("/"+a+"/?$"))})},stringify:l,taggedStringify:function(a){for(var b=arguments.length,c=Array(1<b?b-1:0),d=1;d<b;d++)c[d-
1]=arguments[d];return a.reduce(function(a,b,d){return a+b+(l(c[d])||"")},"")},short:function(a,b){return function(c){return function(d){return a(d)?b(d):c(d)}}},hasProp:function(a){return function(b){return b in a}},last:function(a){return a[a.length-1]},upperCaseFirstLetter:function(a){return a[0].toUpperCase()+a.slice(1)},lowerCaseFirstLetter:function(a){return a[0].toLowerCase()+a.slice(1)},arrayOrPush:function(a,b,c){return Array.isArray(a[b])?a[b].push(c):a[b]=[c]},assignToObject:function(a,
typeof a?"undefined":_typeof2(a))},m=function(a){return d(a)?a.stack||e(a):a},c=function(a){return a&&"function"===typeof a.then},g=function(a,b){return c(b)?b.then(a):a(b)};b.exports={isObject:d,isPromise:c,liftPromise:g,path:function(a){return function(b){return b.reduce(function(a,b){return a&&a[b]},a)}},pick:function(a){return function(b){return b[a]}},pipe:function(){for(var a=arguments.length,b=Array(a),c=0;c<a;c++)b[c]=arguments[c];return function(a){return b.reduce(function(a,b){return g(b,
a)},a)}},reduce:function(a,b){return function(c){return c.reduce(a,b)}},flatten:function(a){return[].concat.apply([],a)},deepFlatten:function k(a){var b;return(b=[]).concat.apply(b,_toConsumableArray2(a.map(function(a){return Array.isArray(a)?k(a):a})))},map:function(a){return function(b){return b.map(a)}},filter:function(a){return function(b){return b.filter(a)}},identity:function(a){return a},wrapWith:function(a){return function(b){return _defineProperty2({},a,b)}},unwrapFrom:function(a){return function(b){return b[a]}},
promiseAll:function(a){return Promise.all(a)},partial:function(a){for(var b=arguments.length,c=Array(1<b?b-1:0),d=1;d<b;d++)c[d-1]=arguments[d];return function(){for(var b=arguments.length,d=Array(b),f=0;f<b;f++)d[f]=arguments[f];return a.apply(void 0,c.concat(d))}},isIn:function(a,b){return-1!==a.indexOf(b)},containsPath:function(a,b){return a.some(function(a){return b.match(new RegExp("/"+a+"/?$"))})},stringify:m,taggedStringify:function(a){for(var b=arguments.length,c=Array(1<b?b-1:0),d=1;d<b;d++)c[d-
1]=arguments[d];return a.reduce(function(a,b,d){return a+b+(m(c[d])||"")},"")},short:function(a,b){return function(c){return function(d){return a(d)?b(d):c(d)}}},hasProp:function(a){return function(b){return b in a}},last:function(a){return a[a.length-1]},upperCaseFirstLetter:function(a){return a[0].toUpperCase()+a.slice(1)},lowerCaseFirstLetter:function(a){return a[0].toLowerCase()+a.slice(1)},arrayOrPush:function(a,b,c){return Array.isArray(a[b])?a[b].push(c):a[b]=[c]},assignToObject:function(a,
b){return function(c,e){return d(a[b])?a[b][c]=e:a[b]=_defineProperty2({},c,e)}}}},{"json-stringify-safe":7}],22:[function(a,b,h){b.exports={Start:Symbol("Start"),End:Symbol("End"),expect:Symbol("expect"),pass:"pass",fail:"fail"}},{}]},{},[1])(1)});

43
es5/index.js

@ -1387,11 +1387,8 @@ function _toConsumableArray2(arr) { if (Array.isArray(arr)) { for (var i = 0, ar
module.exports = buildTestTree;
}, { "../gunner": 9, "../util/symbols": 22 }], 13: [function (require, module, exports) {
var _require3 = require('perf_hooks'),
performance = _require3.performance;
var _require4 = require('../util'),
isPromise = _require4.isPromise;
var _require3 = require('../util'),
isPromise = _require3.isPromise;
var caller = function caller(test, state) {
@ -1401,11 +1398,11 @@ function _toConsumableArray2(arr) { if (Array.isArray(arr)) { for (var i = 0, ar
error = void 0,
errored = void 0;
try {
perf.start = performance.now();
perf.start = Date.now();
value = test(state);
perf.end = performance.now();
perf.end = Date.now();
} catch (e) {
perf.end = performance.now();
perf.end = Date.now();
errored = true;
error = e;
}
@ -1415,14 +1412,14 @@ function _toConsumableArray2(arr) { if (Array.isArray(arr)) { for (var i = 0, ar
if (promise) {
return value.then(function (res) {
return {
duration: performance.now() - perf.start,
duration: Date.now() - perf.start,
status: 'ok',
resolve: res,
promise: true
};
}).catch(function (rej) {
return {
duration: performance.now() - perf.start,
duration: Date.now() - perf.start,
status: 'notOk',
rejection: rej,
promise: true
@ -1439,7 +1436,7 @@ function _toConsumableArray2(arr) { if (Array.isArray(arr)) { for (var i = 0, ar
};
module.exports = caller;
}, { "../util": 21, "perf_hooks": 5 }], 14: [function (require, module, exports) {
}, { "../util": 21 }], 14: [function (require, module, exports) {
var EventEmitter = require('events');
var GunnerEmitter = function (_EventEmitter) {
@ -1458,9 +1455,9 @@ function _toConsumableArray2(arr) { if (Array.isArray(arr)) { for (var i = 0, ar
}, { "events": 6 }], 15: [function (require, module, exports) {
'use strict';
var _require5 = require('../util'),
liftPromise = _require5.liftPromise,
lowerCaseFirstLetter = _require5.lowerCaseFirstLetter;
var _require4 = require('../util'),
liftPromise = _require4.liftPromise,
lowerCaseFirstLetter = _require4.lowerCaseFirstLetter;
var library = require('./assertionsLibrary');
var assertPromise = require('./assertPromise');
@ -1526,14 +1523,14 @@ function _toConsumableArray2(arr) { if (Array.isArray(arr)) { for (var i = 0, ar
var Gunner = require('../gunner');
Promise.object = require('@codefeathers/promise.object');
var _require6 = require('perf_hooks'),
performance = _require6.performance;
var _require5 = require('perf_hooks'),
performance = _require5.performance;
var _require7 = require('../util'),
last = _require7.last,
pipe = _require7.pipe,
pick = _require7.pick,
assignToObject = _require7.assignToObject;
var _require6 = require('../util'),
last = _require6.last,
pipe = _require6.pipe,
pick = _require6.pick,
assignToObject = _require6.assignToObject;
var buildTestQueue = require('./buildTestQueue');
@ -1618,10 +1615,10 @@ function _toConsumableArray2(arr) { if (Array.isArray(arr)) { for (var i = 0, ar
*/
var testrunner = function testrunner(instance) {
var perf = { start: performance.now() };
var perf = { start: Date.now() };
return Promise.object(pipe(buildTestQueue, reduceQueue, pick('results'))(instance)).then(function (results) {
results.duration = performance.now() - perf.start;
results.duration = Date.now() - perf.start;
return results;
});
};

2
package.json

@ -1,6 +1,6 @@
{
"name": "@klenty/gunner",
"version": "0.10.6",
"version": "0.10.7",
"description": "Zero magic, fast test-runner and assertion framework. No magic globals.",
"main": "es6/index.js",
"repository": {

Loading…
Cancel
Save