We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c957a95 commit 86e2dd7Copy full SHA for 86e2dd7
src/packages/core/utils/math/distance.test.ts
@@ -0,0 +1,10 @@
1
+import { expect } from '@open-wc/testing';
2
+import { distance } from './math.js';
3
+
4
+describe('distance', () => {
5
+ it('should return the distance between two points', () => {
6
+ expect(distance(5, 10)).to.equal(5);
7
+ expect(distance(5.86732, 10.3989328)).to.equal(4.5316128);
8
+ expect(distance(-25.8673, 12912.47831)).to.equal(12938.34561);
9
+ });
10
+});
0 commit comments