-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtestFramework.js.map
13 lines (13 loc) · 3.68 KB
/
testFramework.js.map
1
2
3
4
5
6
7
8
9
10
11
12
13
{
"version": 3,
"file": "testFramework.js",
"sourceRoot": "\\",
"sources": [
"src\\testFramework.coffee"
],
"names": [],
"mappings": ";AAAA,IAAA,OAAA,EAAA,IAAA,EAAA,MAAA,EAAA,SAAA,EAAA,IAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,OAAA,EAAA,KAAA,EAAA,OAAA,EAAA,OAAA;EAAA;;AAAA,CAAA,CAAC,OAAD,EAAU,QAAV,EAAoB,UAApB,CAAA,GAAkC,OAAA,CAAQ,UAAR,CAAlC;;AACA,OAAA,GAAU,CAAC,WAAD,CAAA,GAAA;SAAiB,CAAC,CAAD,CAAA,GAAA;IACzB,QAAA,CAAS,CAAA,KAAA,CAAA,CAAQ,WAAR,CAAA,OAAA,CAAT;IACA,IAAc,SAAd;MAAA,QAAA,CAAS,CAAT,EAAA;;WACA;EAHyB;AAAjB;;AAKV,KAAA,GAAQ;;AACR,OAAA,GAAU;;AAEV,OAAA,GAAU,CAAA,CAAA,GAAA;EACR,OAAA,IAAW;EACX,IAAG,OAAA,GAAU,CAAV,IAAgB,KAAK,CAAC,MAAN,GAAe,CAAlC;IACE,OAAA,IAAW;WACX,KAAK,CAAC,KAAN,CAAA,CAAA,CAAA,EAFF;;AAFQ;;AAMV,IAAA,GAAO,CAAC,WAAD,CAAA,GAAA;AACP,MAAA,IAAA,EAAA,IAAA,EAAA,GAAA,EAAA,GAAA,EAAA,MAAA,EAAA;EAAE,IAAA,GAAO,OAAA,CAAQ,WAAR;EACP,IAAA,GAAO;EACP,MAAA,GAAS,CAAE,IAAF;AACT;EAAA,KAAA,UAAA;;;IACE,MAAM,CAAC,GAAD,CAAN,GAAiB,CAAA,CAAC,KAAD,CAAA,GAAA;aAAW,CAAA,GAAI,IAAJ,CAAA,GAAA;eAC1B,KAAA,CAA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,IAAI,OAAJ,CAAY,CAAC,OAAD,CAAA,GAAA;WAAa,CAAA,GAAI;EAAjB,CAAZ;EACJ,OAAA,IAAW;EACX,KAAK,CAAC,IAAN,CAAW,CAAX;SACA;AALK;;AAOP,OAAA,GAAU,CAAA,CAAA,GAAA;SAAG;IAAC,MAAD;IAAS,SAAA,EAAc;EAAvB;AAAH;;AAEV,MAAM,CAAC,OAAP,GAAiB",
"sourcesContent": [
"{logInfo, logError, isFunction} = require './common'\r\nlogFail = (description) => (e) =>\r\n logError \"Test #{description} failed\"\r\n logError e if e?\r\n false\r\n\r\nqueue = []\r\nrunning = 0\r\n\r\ntestEnd = =>\r\n running -= 1\r\n if running < 1 and queue.length > 0\r\n running += 1\r\n queue.shift()()\r\n\r\nTest = (description) =>\r\n fail = logFail description\r\n flag = true\r\n report = { idle }\r\n for own key, value of do Asserts\r\n report[key] = do (value) => (...args) =>\r\n value ...args\r\n .catch fail\r\n .then (res) =>\r\n flag = flag and !!res\r\n\r\n (testFn) =>\r\n running += 1\r\n Promise.resolve()\r\n .then => testFn report\r\n .then =>\r\n if flag\r\n logInfo \"Test #{description} passed\"\r\n else do fail\r\n .catch fail\r\n .then testEnd\r\n\r\nassert = (flag, message = 'assert failed') =>\r\n flag = await flag\r\n if not flag then throw new Error message\r\n true\r\n\r\nassertSeq = =>\r\n count = -Infinity\r\n (c, message = 'wrong sequence') =>\r\n c = await c\r\n if count > c\r\n throw new Error message\r\n else\r\n if isFinite(c) or c is Infinity then count = +c\r\n true\r\n\r\nidle = (r, p) =>\r\n if running < 2 then return\r\n p = new Promise((resolve) => r = resolve)\r\n running -= 1\r\n queue.push(r)\r\n p\r\n\r\nAsserts = => {assert, assertSeq: do assertSeq}\r\n\r\nmodule.exports = Test\r\n"
]
}