UNPKG

26.8 kBJavaScriptView Raw
1/**
2 * Testing framework with support for generating tests.
3 *
4 * ```js
5 * // test.js template for creating a test executable
6 * import { runTests } from 'lib0/testing'
7 * import * as log from 'lib0/logging'
8 * import * as mod1 from './mod1.test.js'
9 * import * as mod2 from './mod2.test.js'
10
11 * import { isBrowser, isNode } from 'lib0/environment.js'
12 *
13 * if (isBrowser) {
14 * // optional: if this is ran in the browser, attach a virtual console to the dom
15 * log.createVConsole(document.body)
16 * }
17 *
18 * runTests({
19 * mod1,
20 * mod2,
21 * }).then(success => {
22 * if (isNode) {
23 * process.exit(success ? 0 : 1)
24 * }
25 * })
26 * ```
27 *
28 * ```js
29 * // mod1.test.js
30 * /**
31 * * runTests automatically tests all exported functions that start with "test".
32 * * The name of the function should be in camelCase and is used for the logging output.
33 * *
34 * * @param {t.TestCase} tc
35 * *\/
36 * export const testMyFirstTest = tc => {
37 * t.compare({ a: 4 }, { a: 4 }, 'objects are equal')
38 * }
39 * ```
40 *
41 * Now you can simply run `node test.js` to run your test or run test.js in the browser.
42 *
43 * @module testing
44 */
45
46import * as log from 'lib0/logging'
47import { simpleDiffString } from './diff.js'
48import * as object from './object.js'
49import * as string from './string.js'
50import * as math from './math.js'
51import * as random from './random.js'
52import * as prng from './prng.js'
53import * as statistics from './statistics.js'
54import * as array from './array.js'
55import * as env from './environment.js'
56import * as json from './json.js'
57import * as time from './time.js'
58import * as promise from './promise.js'
59import * as performance from 'lib0/performance'
60
61export { production } from './environment.js'
62
63export const extensive = env.hasConf('extensive')
64
65/* c8 ignore next */
66export const envSeed = env.hasParam('--seed') ? Number.parseInt(env.getParam('--seed', '0')) : null
67
68export class TestCase {
69 /**
70 * @param {string} moduleName
71 * @param {string} testName
72 */
73 constructor (moduleName, testName) {
74 /**
75 * @type {string}
76 */
77 this.moduleName = moduleName
78 /**
79 * @type {string}
80 */
81 this.testName = testName
82 /**
83 * This type can store custom information related to the TestCase
84 *
85 * @type {Map<string,any>}
86 */
87 this.meta = new Map()
88 this._seed = null
89 this._prng = null
90 }
91
92 resetSeed () {
93 this._seed = null
94 this._prng = null
95 }
96
97 /**
98 * @type {number}
99 */
100 /* c8 ignore next */
101 get seed () {
102 /* c8 ignore else */
103 if (this._seed === null) {
104 /* c8 ignore next */
105 this._seed = envSeed === null ? random.uint32() : envSeed
106 }
107 return this._seed
108 }
109
110 /**
111 * A PRNG for this test case. Use only this PRNG for randomness to make the test case reproducible.
112 *
113 * @type {prng.PRNG}
114 */
115 get prng () {
116 /* c8 ignore else */
117 if (this._prng === null) {
118 this._prng = prng.create(this.seed)
119 }
120 return this._prng
121 }
122}
123
124export const repetitionTime = Number(env.getParam('--repetition-time', '50'))
125/* c8 ignore next */
126const testFilter = env.hasParam('--filter') ? env.getParam('--filter', '') : null
127
128/* c8 ignore next */
129const testFilterRegExp = testFilter !== null ? new RegExp(testFilter) : /.*/
130
131const repeatTestRegex = /^(repeat|repeating)\s/
132
133/**
134 * @param {string} moduleName
135 * @param {string} name
136 * @param {function(TestCase):void|Promise<any>} f
137 * @param {number} i
138 * @param {number} numberOfTests
139 */
140export const run = async (moduleName, name, f, i, numberOfTests) => {
141 const uncamelized = string.fromCamelCase(name.slice(4), ' ')
142 const filtered = !testFilterRegExp.test(`[${i + 1}/${numberOfTests}] ${moduleName}: ${uncamelized}`)
143 /* c8 ignore next 3 */
144 if (filtered) {
145 return true
146 }
147 const tc = new TestCase(moduleName, name)
148 const repeat = repeatTestRegex.test(uncamelized)
149 const groupArgs = [log.GREY, `[${i + 1}/${numberOfTests}] `, log.PURPLE, `${moduleName}: `, log.BLUE, uncamelized]
150 /* c8 ignore next 5 */
151 if (testFilter === null) {
152 log.groupCollapsed(...groupArgs)
153 } else {
154 log.group(...groupArgs)
155 }
156 const times = []
157 const start = performance.now()
158 let lastTime = start
159 /**
160 * @type {any}
161 */
162 let err = null
163 performance.mark(`${name}-start`)
164 do {
165 try {
166 const p = f(tc)
167 if (promise.isPromise(p)) {
168 await p
169 }
170 } catch (_err) {
171 err = _err
172 }
173 const currTime = performance.now()
174 times.push(currTime - lastTime)
175 lastTime = currTime
176 if (repeat && err === null && (lastTime - start) < repetitionTime) {
177 tc.resetSeed()
178 } else {
179 break
180 }
181 } while (err === null && (lastTime - start) < repetitionTime)
182 performance.mark(`${name}-end`)
183 /* c8 ignore next 3 */
184 if (err !== null && err.constructor !== SkipError) {
185 log.printError(err)
186 }
187 performance.measure(name, `${name}-start`, `${name}-end`)
188 log.groupEnd()
189 const duration = lastTime - start
190 let success = true
191 times.sort((a, b) => a - b)
192 /* c8 ignore next 3 */
193 const againMessage = env.isBrowser
194 ? ` - ${window.location.host + window.location.pathname}?filter=\\[${i + 1}/${tc._seed === null ? '' : `&seed=${tc._seed}`}`
195 : `\nrepeat: npm run test -- --filter "\\[${i + 1}/" ${tc._seed === null ? '' : `--seed ${tc._seed}`}`
196 const timeInfo = (repeat && err === null)
197 ? ` - ${times.length} repetitions in ${time.humanizeDuration(duration)} (best: ${time.humanizeDuration(times[0])}, worst: ${time.humanizeDuration(array.last(times))}, median: ${time.humanizeDuration(statistics.median(times))}, average: ${time.humanizeDuration(statistics.average(times))})`
198 : ` in ${time.humanizeDuration(duration)}`
199 if (err !== null) {
200 /* c8 ignore start */
201 if (err.constructor === SkipError) {
202 log.print(log.GREY, log.BOLD, 'Skipped: ', log.UNBOLD, uncamelized)
203 } else {
204 success = false
205 log.print(log.RED, log.BOLD, 'Failure: ', log.UNBOLD, log.UNCOLOR, uncamelized, log.GREY, timeInfo, againMessage)
206 }
207 /* c8 ignore stop */
208 } else {
209 log.print(log.GREEN, log.BOLD, 'Success: ', log.UNBOLD, log.UNCOLOR, uncamelized, log.GREY, timeInfo, againMessage)
210 }
211 return success
212}
213
214/**
215 * Describe what you are currently testing. The message will be logged.
216 *
217 * ```js
218 * export const testMyFirstTest = tc => {
219 * t.describe('crunching numbers', 'already crunched 4 numbers!') // the optional second argument can describe the state.
220 * }
221 * ```
222 *
223 * @param {string} description
224 * @param {string} info
225 */
226export const describe = (description, info = '') => log.print(log.BLUE, description, ' ', log.GREY, info)
227
228/**
229 * Describe the state of the current computation.
230 * ```js
231 * export const testMyFirstTest = tc => {
232 * t.info(already crunched 4 numbers!') // the optional second argument can describe the state.
233 * }
234 * ```
235 *
236 * @param {string} info
237 */
238export const info = info => describe('', info)
239
240export const printDom = log.printDom
241
242export const printCanvas = log.printCanvas
243
244/**
245 * Group outputs in a collapsible category.
246 *
247 * ```js
248 * export const testMyFirstTest = tc => {
249 * t.group('subtest 1', () => {
250 * t.describe('this message is part of a collapsible section')
251 * })
252 * await t.groupAsync('subtest async 2', async () => {
253 * await someaction()
254 * t.describe('this message is part of a collapsible section')
255 * })
256 * }
257 * ```
258 *
259 * @param {string} description
260 * @param {function(...any):void} f
261 */
262export const group = (description, f) => {
263 log.group(log.BLUE, description)
264 try {
265 f()
266 } finally {
267 log.groupEnd()
268 }
269}
270
271/**
272 * Group outputs in a collapsible category.
273 *
274 * ```js
275 * export const testMyFirstTest = async tc => {
276 * t.group('subtest 1', () => {
277 * t.describe('this message is part of a collapsible section')
278 * })
279 * await t.groupAsync('subtest async 2', async () => {
280 * await someaction()
281 * t.describe('this message is part of a collapsible section')
282 * })
283 * }
284 * ```
285 *
286 * @param {string} description
287 * @param {function(...any):Promise<any>} f
288 */
289export const groupAsync = async (description, f) => {
290 log.group(log.BLUE, description)
291 try {
292 await f()
293 } finally {
294 log.groupEnd()
295 }
296}
297
298/**
299 * Measure the time that it takes to calculate something.
300 *
301 * ```js
302 * export const testMyFirstTest = async tc => {
303 * t.measureTime('measurement', () => {
304 * heavyCalculation()
305 * })
306 * await t.groupAsync('async measurement', async () => {
307 * await heavyAsyncCalculation()
308 * })
309 * }
310 * ```
311 *
312 * @param {string} message
313 * @param {function(...any):void} f
314 * @return {number} Returns a promise that resolves the measured duration to apply f
315 */
316export const measureTime = (message, f) => {
317 let duration
318 const start = performance.now()
319 try {
320 f()
321 } finally {
322 duration = performance.now() - start
323 log.print(log.PURPLE, message, log.GREY, ` ${time.humanizeDuration(duration)}`)
324 }
325 return duration
326}
327
328/**
329 * Measure the time that it takes to calculate something.
330 *
331 * ```js
332 * export const testMyFirstTest = async tc => {
333 * t.measureTimeAsync('measurement', async () => {
334 * await heavyCalculation()
335 * })
336 * await t.groupAsync('async measurement', async () => {
337 * await heavyAsyncCalculation()
338 * })
339 * }
340 * ```
341 *
342 * @param {string} message
343 * @param {function(...any):Promise<any>} f
344 * @return {Promise<number>} Returns a promise that resolves the measured duration to apply f
345 */
346export const measureTimeAsync = async (message, f) => {
347 let duration
348 const start = performance.now()
349 try {
350 await f()
351 } finally {
352 duration = performance.now() - start
353 log.print(log.PURPLE, message, log.GREY, ` ${time.humanizeDuration(duration)}`)
354 }
355 return duration
356}
357
358/**
359 * @template T
360 * @param {Array<T>} as
361 * @param {Array<T>} bs
362 * @param {string} [m]
363 * @return {boolean}
364 */
365export const compareArrays = (as, bs, m = 'Arrays match') => {
366 if (as.length !== bs.length) {
367 fail(m)
368 }
369 for (let i = 0; i < as.length; i++) {
370 if (as[i] !== bs[i]) {
371 fail(m)
372 }
373 }
374 return true
375}
376
377/**
378 * @param {string} a
379 * @param {string} b
380 * @param {string} [m]
381 * @throws {TestError} Throws if tests fails
382 */
383export const compareStrings = (a, b, m = 'Strings match') => {
384 if (a !== b) {
385 const diff = simpleDiffString(a, b)
386 log.print(log.GREY, a.slice(0, diff.index), log.RED, a.slice(diff.index, diff.remove), log.GREEN, diff.insert, log.GREY, a.slice(diff.index + diff.remove))
387 fail(m)
388 }
389}
390
391/**
392 * @template K,V
393 * @param {Object<K,V>} a
394 * @param {Object<K,V>} b
395 * @param {string} [m]
396 * @throws {TestError} Throws if test fails
397 */
398export const compareObjects = (a, b, m = 'Objects match') => { object.equalFlat(a, b) || fail(m) }
399
400/**
401 * @param {any} _constructor
402 * @param {any} a
403 * @param {any} b
404 * @param {string} path
405 * @throws {TestError}
406 */
407const compareValues = (_constructor, a, b, path) => {
408 if (a !== b) {
409 fail(`Values ${json.stringify(a)} and ${json.stringify(b)} don't match (${path})`)
410 }
411 return true
412}
413
414/**
415 * @param {string?} message
416 * @param {string} reason
417 * @param {string} path
418 * @throws {TestError}
419 */
420const _failMessage = (message, reason, path) => fail(
421 message === null
422 ? `${reason} ${path}`
423 : `${message} (${reason}) ${path}`
424)
425
426/**
427 * @param {any} a
428 * @param {any} b
429 * @param {string} path
430 * @param {string?} message
431 * @param {function(any,any,any,string,any):boolean} customCompare
432 */
433const _compare = (a, b, path, message, customCompare) => {
434 // we don't use assert here because we want to test all branches (istanbul errors if one branch is not tested)
435 if (a == null || b == null) {
436 return compareValues(null, a, b, path)
437 }
438 if (a.constructor !== b.constructor) {
439 _failMessage(message, 'Constructors don\'t match', path)
440 }
441 let success = true
442 switch (a.constructor) {
443 case ArrayBuffer:
444 a = new Uint8Array(a)
445 b = new Uint8Array(b)
446 // eslint-disable-next-line no-fallthrough
447 case Uint8Array: {
448 if (a.byteLength !== b.byteLength) {
449 _failMessage(message, 'ArrayBuffer lengths match', path)
450 }
451 for (let i = 0; success && i < a.length; i++) {
452 success = success && a[i] === b[i]
453 }
454 break
455 }
456 case Set: {
457 if (a.size !== b.size) {
458 _failMessage(message, 'Sets have different number of attributes', path)
459 }
460 // @ts-ignore
461 a.forEach(value => {
462 if (!b.has(value)) {
463 _failMessage(message, `b.${path} does have ${value}`, path)
464 }
465 })
466 break
467 }
468 case Map: {
469 if (a.size !== b.size) {
470 _failMessage(message, 'Maps have different number of attributes', path)
471 }
472 // @ts-ignore
473 a.forEach((value, key) => {
474 if (!b.has(key)) {
475 _failMessage(message, `Property ${path}["${key}"] does not exist on second argument`, path)
476 }
477 _compare(value, b.get(key), `${path}["${key}"]`, message, customCompare)
478 })
479 break
480 }
481 case Object:
482 if (object.length(a) !== object.length(b)) {
483 _failMessage(message, 'Objects have a different number of attributes', path)
484 }
485 object.forEach(a, (value, key) => {
486 if (!object.hasProperty(b, key)) {
487 _failMessage(message, `Property ${path} does not exist on second argument`, path)
488 }
489 _compare(value, b[key], `${path}["${key}"]`, message, customCompare)
490 })
491 break
492 case Array:
493 if (a.length !== b.length) {
494 _failMessage(message, 'Arrays have a different number of attributes', path)
495 }
496 // @ts-ignore
497 a.forEach((value, i) => _compare(value, b[i], `${path}[${i}]`, message, customCompare))
498 break
499 /* c8 ignore next 4 */
500 default:
501 if (!customCompare(a.constructor, a, b, path, compareValues)) {
502 _failMessage(message, `Values ${json.stringify(a)} and ${json.stringify(b)} don't match`, path)
503 }
504 }
505 assert(success, message)
506 return true
507}
508
509/**
510 * @template T
511 * @param {T} a
512 * @param {T} b
513 * @param {string?} [message]
514 * @param {function(any,T,T,string,any):boolean} [customCompare]
515 */
516export const compare = (a, b, message = null, customCompare = compareValues) => _compare(a, b, 'obj', message, customCompare)
517
518/**
519 * @template T
520 * @param {T} property
521 * @param {string?} [message]
522 * @return {asserts property is NonNullable<T>}
523 * @throws {TestError}
524 */
525/* c8 ignore next */
526export const assert = (property, message = null) => { property || fail(`Assertion failed${message !== null ? `: ${message}` : ''}`) }
527
528/**
529 * @param {function(...any):Promise<any>} f
530 */
531export const promiseRejected = async f => {
532 try {
533 await f()
534 } catch (err) {
535 return
536 }
537 fail('Expected promise to fail')
538}
539
540/**
541 * @param {function(...any):void} f
542 * @throws {TestError}
543 */
544export const fails = f => {
545 try {
546 f()
547 } catch (_err) {
548 log.print(log.GREEN, '⇖ This Error was expected')
549 return
550 }
551 fail('Expected this to fail')
552}
553
554/**
555 * @param {function(...any):Promise<any>} f
556 * @throws {TestError}
557 */
558export const failsAsync = async f => {
559 try {
560 await f()
561 } catch (_err) {
562 log.print(log.GREEN, '⇖ This Error was expected')
563 return
564 }
565 fail('Expected this to fail')
566}
567
568/**
569 * @param {Object<string, Object<string, function(TestCase):void|Promise<any>>>} tests
570 */
571export const runTests = async tests => {
572 /**
573 * @param {string} testname
574 */
575 const filterTest = testname => testname.startsWith('test') || testname.startsWith('benchmark')
576 const numberOfTests = object.map(tests, mod => object.map(mod, (f, fname) => /* c8 ignore next */ f && filterTest(fname) ? 1 : 0).reduce(math.add, 0)).reduce(math.add, 0)
577 let successfulTests = 0
578 let testnumber = 0
579 const start = performance.now()
580 for (const modName in tests) {
581 const mod = tests[modName]
582 for (const fname in mod) {
583 const f = mod[fname]
584 /* c8 ignore else */
585 if (f && filterTest(fname)) {
586 const repeatEachTest = 1
587 let success = true
588 for (let i = 0; success && i < repeatEachTest; i++) {
589 success = await run(modName, fname, f, testnumber, numberOfTests)
590 }
591 testnumber++
592 /* c8 ignore else */
593 if (success) {
594 successfulTests++
595 }
596 }
597 }
598 }
599 const end = performance.now()
600 log.print('')
601 const success = successfulTests === numberOfTests
602 /* c8 ignore start */
603 if (success) {
604 log.print(log.GREEN, log.BOLD, 'All tests successful!', log.GREY, log.UNBOLD, ` in ${time.humanizeDuration(end - start)}`)
605 log.printImgBase64(nyanCatImage, 50)
606 } else {
607 const failedTests = numberOfTests - successfulTests
608 log.print(log.RED, log.BOLD, `> ${failedTests} test${failedTests > 1 ? 's' : ''} failed`)
609 }
610 /* c8 ignore stop */
611 return success
612}
613
614class TestError extends Error {}
615
616/**
617 * @param {string} reason
618 * @throws {TestError}
619 */
620export const fail = reason => {
621 log.print(log.RED, log.BOLD, 'X ', log.UNBOLD, reason)
622 throw new TestError('Test Failed')
623}
624
625class SkipError extends Error {}
626
627/**
628 * @param {boolean} cond If true, this tests will be skipped
629 * @throws {SkipError}
630 */
631export const skip = (cond = true) => {
632 if (cond) {
633 throw new SkipError('skipping..')
634 }
635}
636
637// eslint-disable-next-line
638const nyanCatImage = 'R0lGODlhjABMAPcAAMiSE0xMTEzMzUKJzjQ0NFsoKPc7//FM/9mH/z9x0HIiIoKCgmBHN+frGSkZLdDQ0LCwsDk71g0KCUzDdrQQEOFz/8yYdelmBdTiHFxcXDU2erR/mLrTHCgoKK5szBQUFNgSCTk6ymfpCB9VZS2Bl+cGBt2N8kWm0uDcGXhZRUvGq94NCFPhDiwsLGVlZTgqIPMDA1g3aEzS5D6xAURERDtG9JmBjJsZ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