chore: 添加第三方依赖库
This commit is contained in:
15
thirdparty/rapier.js/rapier-compat/tests/math2d.test.ts
vendored
Normal file
15
thirdparty/rapier.js/rapier-compat/tests/math2d.test.ts
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
import {Vector2, VectorOps} from "../builds/2d-deterministic/pkg";
|
||||
|
||||
describe("2d/math", () => {
|
||||
test("Vector2", () => {
|
||||
const v = new Vector2(0, 1);
|
||||
expect(v.x).toBe(0);
|
||||
expect(v.y).toBe(1);
|
||||
});
|
||||
|
||||
test("VectorOps", () => {
|
||||
const v = VectorOps.new(0, 1);
|
||||
expect(v.x).toBe(0);
|
||||
expect(v.y).toBe(1);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user