Auto merge of #21824 - sfackler:should_panic, r=alexcrichton
This commit is contained in:
commit
638832e64c
42 changed files with 136 additions and 128 deletions
|
|
@ -14,7 +14,7 @@
|
|||
// ignore-pretty: does not work well with `--test`
|
||||
|
||||
#[test]
|
||||
#[should_fail(expected = "foobar")]
|
||||
#[should_panic(expected = "foobar")]
|
||||
fn test_foo() {
|
||||
panic!("blah")
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,13 +12,13 @@
|
|||
// ignore-pretty: does not work well with `--test`
|
||||
|
||||
#[test]
|
||||
#[should_fail(expected = "foo")]
|
||||
#[should_panic(expected = "foo")]
|
||||
fn test_foo() {
|
||||
panic!("foo bar")
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[should_fail(expected = "foo")]
|
||||
#[should_panic(expected = "foo")]
|
||||
fn test_foo_dynamic() {
|
||||
panic!("{} bar", "foo")
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue