From 8e16d8fbfd8750ab35cb3344854cfeae2f4c629e Mon Sep 17 00:00:00 2001 From: ssube Date: Thu, 22 Jul 2021 13:18:45 -0500 Subject: [PATCH] use expect for throw test, limit runs --- test/TestOver.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/test/TestOver.ts b/test/TestOver.ts index 826b614..6555d99 100644 --- a/test/TestOver.ts +++ b/test/TestOver.ts @@ -16,11 +16,7 @@ describe('example properties', () => { }); it('should not throw', (n: number) => { - if (n.toString()[3] === '9') { - throw new Error('not a real number!'); - } - - return true; + expect(n).to.equal(9); }); it('should resolve async checks', async (n: number) => { @@ -44,7 +40,7 @@ describe('example properties', () => { }, { // fast-check parameters are supported, like examples examples: ['a', 'b'], - numRuns: 1_000_000_000, + numRuns: 1_000, }); over('even numbers', integer().filter(n => n % 2 === 0), (it) => {