]> git.lizzy.rs Git - rust.git/blob - src/test/ui/test-attrs/test-should-fail-good-message.rs
Override rustc version in ui and mir-opt tests to get stable hashes
[rust.git] / src / test / ui / test-attrs / test-should-fail-good-message.rs
1 // run-pass
2 // needs-unwind
3 // ignore-wasm32-bare compiled with panic=abort by default
4 // compile-flags: --test
5 #[test]
6 #[should_panic(expected = "foo")]
7 pub fn test_foo() {
8     panic!("foo bar")
9 }
10
11 #[test]
12 #[should_panic(expected = "foo")]
13 pub fn test_foo_dynamic() {
14     panic!("{} bar", "foo")
15 }