| 13 | export const disableFeatures = ['clocks']; |
| 14 | |
| 15 | export async function test(run) { |
| 16 | const curNow = Date.now(); |
| 17 | const { stdout, stderr } = await run(); |
| 18 | strictEqual(stderr, ''); |
| 19 | const times = stdout.split('\n'); |
| 20 | |
| 21 | // verify now was taken at build time |
| 22 | // NOTE: While build time is expected to be within 15 seconds, |
| 23 | // we avoid ensuring a specific bound on build time due to the |
| 24 | // unreliability of combinations of CI systems and specific OSes |
| 25 | ok(Number(times[0]) < curNow); |
| 26 | |
| 27 | // verify disabled time doesn't progress |
| 28 | strictEqual(times[1], times[0]); |
| 29 | } |