1 2 3 4 5 6 7 8 9 10 11
#![feature(assert_matches)] use std::assert_matches::assert_matches; use conflag; use conflag::Value; #[test] fn test_call_builtin() { let v = conflag::parse("if(true, 1, 2)").unwrap(); assert_matches!(*v, Value::Number(n) if n == 1.); }