core: Shuffle around a #fmt test

This commit is contained in:
Brian Anderson 2012-01-21 13:20:03 -08:00
parent 059e243b16
commit 8c92ea49d3
2 changed files with 6 additions and 9 deletions

View File

@ -453,15 +453,6 @@ mod rt {
}
}
#[cfg(test)]
mod tests {
#[test]
fn test_percent() {
let s = #fmt["ab%%cd"];
assert(s == "ab%cd");
}
}
// Local Variables:
// mode: rust;
// fill-column: 78;

View File

@ -21,6 +21,7 @@ fn main() {
part4();
part5();
part6();
percent();
}
fn part1() {
@ -229,3 +230,8 @@ fn part6() {
test(#fmt["%-+05d", 1], "+1 ");
test(#fmt["%-+05d", -1], "-1 ");
}
fn percent() {
let s = #fmt["ab%%cd"];
assert(s == "ab%cd");
}