Skip to content

🎥 Make videos programmatically with React

Update spring.test.ts

Jonny Burger69a159b3826c
diff --git a/packages/core/src/test/spring.test.ts b/packages/core/src/test/spring.test.ts
index 3027f3bc7f..21cb723dbe 100644
--- a/packages/core/src/test/spring.test.ts
+++ b/packages/core/src/test/spring.test.ts
@@ -223,3 +223,17 @@ test('spring should not end too early', () => {
}),
).toBeCloseTo(1);
});
+
+test('from / to', () => {
+ expect(
+ spring({
+ fps: 30,
+ frame: 10,
+ from: 0,
+ to: 200,
+ config: {
+ damping: 200,
+ },
+ }),
+ ).toBeCloseTo(169.082);
+});