Add fmt::Debug
string escape tests
This commit is contained in:
parent
24b5d3afd7
commit
025ca11ab9
@ -74,6 +74,10 @@ pub fn main() {
|
||||
t!(format!("{:?}", 10_usize), "10");
|
||||
t!(format!("{:?}", "true"), "\"true\"");
|
||||
t!(format!("{:?}", "foo\nbar"), "\"foo\\nbar\"");
|
||||
t!(format!("{:?}", "foo\n\"bar\"\r\n\'baz\'\t\\qux\\"),
|
||||
r#""foo\n\"bar\"\r\n\'baz\'\t\\qux\\""#);
|
||||
t!(format!("{:?}", "foo\0bar\x01baz\u{3b1}q\u{75}x"),
|
||||
r#""foo\u{0}bar\u{1}baz\u{3b1}qux""#);
|
||||
t!(format!("{:o}", 10_usize), "12");
|
||||
t!(format!("{:x}", 10_usize), "a");
|
||||
t!(format!("{:X}", 10_usize), "A");
|
||||
|
Loading…
Reference in New Issue
Block a user