Skip to content

Commit

Permalink
bigint test suite (#94)
Browse files Browse the repository at this point in the history
  • Loading branch information
kubikowski committed Jun 4, 2024
1 parent 3a7b34d commit d074633
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
18 changes: 18 additions & 0 deletions test/util/test-sets/big-int-test-sets.model.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import { TestSets } from './test-sets.model';

export class BigIntTestSets extends TestSets<bigint> {
public constructor() {
super(
BigInt(0),
BigInt(1),
BigInt(2),
BigInt(3),
BigInt(4),
BigInt(5),
BigInt(6),
BigInt(7),
BigInt(8),
BigInt(9),
);
}
}
2 changes: 2 additions & 0 deletions test/util/test-suite.function.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { describe } from '@jest/globals';
import { ArrayTestSets } from './test-sets/array-test-sets.model';
import { BigIntTestSets } from './test-sets/big-int-test-sets.model';
import { DateTestSets } from './test-sets/date-test-sets.model';
import { EnumTestSets } from './test-sets/enum-test-sets.model';
import { ErrorTestSets } from './test-sets/error-test-sets.model';
Expand All @@ -15,6 +16,7 @@ import { TestSets } from './test-sets/test-sets.model';

export function testSuite(name: string, tests: (testSets: TestSets<unknown>) => void): void {
describe(`${ name } ⋅ array`, () => tests(new ArrayTestSets()));
describe(`${ name } ⋅ bigint`, () => tests(new BigIntTestSets()));
describe(`${ name } ⋅ date`, () => tests(new DateTestSets()));
describe(`${ name } ⋅ enum`, () => tests(new EnumTestSets()));
describe(`${ name } ⋅ error`, () => tests(new ErrorTestSets()));
Expand Down

0 comments on commit d074633

Please sign in to comment.