diff --git a/src/function/debounce.spec.ts b/src/function/debounce.spec.ts index a7198c5..9c691e2 100644 --- a/src/function/debounce.spec.ts +++ b/src/function/debounce.spec.ts @@ -45,7 +45,7 @@ describe('Debounce Function', () => { const executedIn = new Date().getTime() - started; expect(foo).toBe(1); - expect(executedIn).toBeGreaterThan(49); + expect(executedIn).toBeGreaterThan(48); expect(executedIn).toBeLessThan(60); done(); diff --git a/src/function/proto/debounce.spec.ts b/src/function/proto/debounce.spec.ts index d95f955..f8798e7 100644 --- a/src/function/proto/debounce.spec.ts +++ b/src/function/proto/debounce.spec.ts @@ -31,7 +31,7 @@ describe('Debounce Proto Function', () => { foo.debounce(50, bar, 0, 0) .then(() => { const sequence = new Date().getTime() - startedAt; - expect(sequence).toBeGreaterThan(49); + expect(sequence).toBeGreaterThan(48); expect(sequence).toBeLessThan(60); expect(bar.x).toBe(8); diff --git a/src/open-promise.spec.ts b/src/open-promise.spec.ts index 3dca757..570a280 100644 --- a/src/open-promise.spec.ts +++ b/src/open-promise.spec.ts @@ -13,7 +13,7 @@ describe('Open Promise Class', () => { const startedAt = new Date().getTime(); op.promise.then(value => { - expect(new Date().getTime() - startedAt).toBeGreaterThan(49); + expect(new Date().getTime() - startedAt).toBeGreaterThan(48); expect(value).toBe(1); done(); }); @@ -89,7 +89,7 @@ describe('Open Promise Class', () => { const startedAt = new Date().getTime(); op.promise.then(val => { - expect(new Date().getTime() - startedAt).toBeGreaterThan(49); + expect(new Date().getTime() - startedAt).toBeGreaterThan(48); expect(val).toBe(1); done(); }); @@ -106,7 +106,7 @@ describe('Open Promise Class', () => { throw new CustomError('bar'); }) .catch((err: CustomError) => { - expect(new Date().getTime() - startedAt).toBeGreaterThan(49); + expect(new Date().getTime() - startedAt).toBeGreaterThan(48); expect(err.message).toBe('foo'); done(); }); diff --git a/src/promise/static/timeout.spec.ts b/src/promise/static/timeout.spec.ts index 4f15686..a2ff6b1 100644 --- a/src/promise/static/timeout.spec.ts +++ b/src/promise/static/timeout.spec.ts @@ -12,7 +12,7 @@ describe('Promise Timeout Static Function', () => { Promise.timeout(50) .then(() => { - expect(new Date().getTime() - startedAt).toBeGreaterThan(49); + expect(new Date().getTime() - startedAt).toBeGreaterThan(48); done(); }); }); @@ -22,7 +22,7 @@ describe('Promise Timeout Static Function', () => { Promise.timeout(50, 'foo') .then(val => { - expect(new Date().getTime() - startedAt).toBeGreaterThan(49); + expect(new Date().getTime() - startedAt).toBeGreaterThan(48); expect(val).toBe('foo'); done(); }); diff --git a/src/promise/timeout.spec.ts b/src/promise/timeout.spec.ts index 6e675c8..1a02067 100644 --- a/src/promise/timeout.spec.ts +++ b/src/promise/timeout.spec.ts @@ -12,7 +12,7 @@ describe('Timeout Promise Function', () => { timeout(50) .then(() => { - expect(new Date().getTime() - startedAt).toBeGreaterThan(49); + expect(new Date().getTime() - startedAt).toBeGreaterThan(48); done(); }); }); @@ -22,7 +22,7 @@ describe('Timeout Promise Function', () => { timeout(50, 'foo') .then(val => { - expect(new Date().getTime() - startedAt).toBeGreaterThan(49); + expect(new Date().getTime() - startedAt).toBeGreaterThan(48); expect(val).toBe('foo'); done(); });