mirror of
https://github.com/ferdikoomen/openapi-typescript-codegen.git
synced 2025-12-08 20:16:21 +00:00
13 lines
491 B
TypeScript
13 lines
491 B
TypeScript
import { unique } from './unique';
|
|
|
|
describe('unique', () => {
|
|
it('should return correct index', () => {
|
|
expect(unique('a', 0, ['a', 'b', 'c'])).toBeTruthy();
|
|
expect(unique('a', 1, ['a', 'b', 'c'])).toBeFalsy();
|
|
expect(unique('a', 2, ['a', 'b', 'c'])).toBeFalsy();
|
|
expect(unique('a', 0, ['a', 'b', 'c'])).toBeTruthy();
|
|
expect(unique('a', 1, ['z', 'a', 'b'])).toBeTruthy();
|
|
expect(unique('a', 2, ['y', 'z', 'a'])).toBeTruthy();
|
|
});
|
|
});
|