mirror of https://github.com/01-edu/public.git
davhojt
2 years ago
committed by
Dav Hojt
1 changed files with 25 additions and 0 deletions
@ -0,0 +1,25 @@
|
||||
export const tests = [] |
||||
|
||||
const testOne = async () => { |
||||
return (await processInfo(() => new Promise(resolve => resolve(1)))) === 2 |
||||
} |
||||
|
||||
const testFifteen = async () => { |
||||
return (await processInfo(() => new Promise(resolve => resolve(15)))) === 30 |
||||
} |
||||
|
||||
const testRejectNoNumbers = async () => { |
||||
return ( |
||||
(await processInfo(() => new Promise((resolve, reject) => reject("No numbers")))) === "Error: No numbers" |
||||
) |
||||
} |
||||
|
||||
const testRejectNumberless = async () => { |
||||
return ( |
||||
(await processInfo(() => new Promise((resolve, reject) => reject("Numberless")))) === "Error: Numberless" |
||||
) |
||||
} |
||||
|
||||
tests.push(testOne, testFifteen, testRejectNoNumbers, testRejectNumberless) |
||||
|
||||
Object.freeze(tests) |
Loading…
Reference in new issue