We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 66f33ff commit e79227dCopy full SHA for e79227d
exercises/tests/tests1.rs
@@ -1,21 +1,11 @@
1
-// tests1.rs
2
-//
3
-// Tests are important to ensure that your code does what you think it should
4
-// do. Tests can be run on this file with the following command: rustlings run
5
-// tests1
6
7
-// This test has a problem with it -- make the test compile! Make the test pass!
8
-// Make the test fail!
9
10
-// Execute `rustlings hint tests1` or use the `hint` watch subcommand for a
11
-// hint.
12
-
13
-// I AM NOT DONE
14
15
#[cfg(test)]
16
mod tests {
17
#[test]
18
fn you_can_assert() {
19
- assert!();
+ // 1. 先让测试编译并通过:assert! 接收一个布尔值,传入true即可
+ // assert!(true);
+
+ // 2. 让测试失败:传入false(取消注释下面这行,注释上面的true)
+ assert!(false);
20
}
21
0 commit comments