From 3e46263347ba18732eabad04c9fbe521bacca46c Mon Sep 17 00:00:00 2001 From: Stephen Chung Date: Sun, 16 Oct 2022 12:07:47 +0800 Subject: [PATCH] Fix tests. --- tests/switch.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/switch.rs b/tests/switch.rs index 8008ccf2..2a4aed98 100644 --- a/tests/switch.rs +++ b/tests/switch.rs @@ -52,7 +52,7 @@ fn test_switch() -> Result<(), Box> { 123 ); assert_eq!( - engine.eval::("let x = timestamp(); switch x { 1 => 123, _ => 42 }")?, + engine.eval_with_scope::(&mut scope, "switch x { 424242 => 123, _ => 42 }")?, 42 ); assert_eq!(