]> git.proxmox.com Git - rustc.git/blame - src/doc/book/listings/ch11-writing-automated-tests/output-only-01-show-output/output.txt
New upstream version 1.54.0+dfsg1
[rustc.git] / src / doc / book / listings / ch11-writing-automated-tests / output-only-01-show-output / output.txt
CommitLineData
74b04a01
XL
1$ cargo test -- --show-output
2 Compiling silly-function v0.1.0 (file:///projects/silly-function)
3 Finished test [unoptimized + debuginfo] target(s) in 0.60s
17df50a5 4 Running unittests (target/debug/deps/silly_function-160869f38cff9166)
74b04a01
XL
5
6running 2 tests
7test tests::this_test_will_fail ... FAILED
8test tests::this_test_will_pass ... ok
9
10successes:
11
12---- tests::this_test_will_pass stdout ----
13I got the value 4
14
15
16successes:
17 tests::this_test_will_pass
18
19failures:
20
21---- tests::this_test_will_fail stdout ----
22I got the value 8
23thread 'main' panicked at 'assertion failed: `(left == right)`
24 left: `5`,
25 right: `10`', src/lib.rs:19:9
fc512014 26note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
74b04a01
XL
27
28
29failures:
30 tests::this_test_will_fail
31
6a06907d 32test result: FAILED. 1 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s
74b04a01
XL
33
34error: test failed, to rerun pass '--lib'