Add a test for special case macros like format! and assert!
This commit is contained in:
parent
07106d444c
commit
72cac8beae
2 changed files with 23 additions and 0 deletions
|
|
@ -216,3 +216,11 @@ make_test!(str_searcher_ascii_haystack, "bb", "abbcbbd", [
|
|||
Reject(6, 7),
|
||||
]);
|
||||
}
|
||||
|
||||
fn special_case_macros() {
|
||||
// format!
|
||||
let s = format!("Arr! While plunderin' the hold, we got '{}' when given '{}' (we expected '{}')", result, input, expected);
|
||||
|
||||
// assert!
|
||||
assert!(result, "Arr! While plunderin' the hold, we got '{}' when given '{}' (we expected '{}')", result, input, expected);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -270,3 +270,18 @@ fn issue2214() {
|
|||
]
|
||||
);
|
||||
}
|
||||
|
||||
fn special_case_macros() {
|
||||
// format!
|
||||
let s = format!(
|
||||
"Arr! While plunderin' the hold, we got '{}' when given '{}' (we expected '{}')",
|
||||
result, input, expected
|
||||
);
|
||||
|
||||
// assert!
|
||||
assert!(
|
||||
result,
|
||||
"Arr! While plunderin' the hold, we got '{}' when given '{}' (we expected '{}')",
|
||||
result, input, expected
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue