Skip to content

Commit

Permalink
test: add zoom (WIP)
Browse files Browse the repository at this point in the history
  • Loading branch information
nobkd committed Apr 4, 2023
1 parent 1644cb6 commit fd10f3e
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion test/map/utils/zoom.test.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
import { describe, it } from 'vitest';
import { getMapZoom } from '../../../src/map/utils/zoom';

describe.concurrent('', () => {});
describe.concurrent('', () => {
it('zoom > 19', ({expect}) => {
const res = getMapZoom(1);

expect(res).toBeTypeOf('number');
expect(res).toBe(19);
});

it('zoom < 0', ({expect}) => {
const res = getMapZoom(100000000);

expect(res).toBeTypeOf('number');
expect(res).toBe(0);
});
});

0 comments on commit fd10f3e

Please sign in to comment.