Skip to content

Commit fd10f3e

Browse files
committed
test: add zoom (WIP)
1 parent 1644cb6 commit fd10f3e

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

test/map/utils/zoom.test.ts

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,18 @@
11
import { describe, it } from 'vitest';
2+
import { getMapZoom } from '../../../src/map/utils/zoom';
23

3-
describe.concurrent('', () => {});
4+
describe.concurrent('', () => {
5+
it('zoom > 19', ({expect}) => {
6+
const res = getMapZoom(1);
7+
8+
expect(res).toBeTypeOf('number');
9+
expect(res).toBe(19);
10+
});
11+
12+
it('zoom < 0', ({expect}) => {
13+
const res = getMapZoom(100000000);
14+
15+
expect(res).toBeTypeOf('number');
16+
expect(res).toBe(0);
17+
});
18+
});

0 commit comments

Comments
 (0)