...

摘要: 需求 假如有以下测试用例,同样的逻辑,我们需要测试多组数据。 mod tests { #[test] fn test_add() { let a = 1; let b = 2; assert_eq!(a + b, 3); } } 一般情况下我们不在用例中使用for循环(即subtests子测试模式) 阅读全文
posted @ 2024-05-14 15:22 韩志超 阅读(22) 评论(0) 推荐(0) 编辑