extname: extend testcases to 16 chars
this is sufficient for all filetests to pass without truncating
This commit is contained in:
committed by
Jakob Stoklund Olesen
parent
eb49d9f8bf
commit
9108725b74
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
use std::fmt::{self, Write};
|
use std::fmt::{self, Write};
|
||||||
|
|
||||||
const TESTCASE_NAME_LENGTH: usize = 10;
|
const TESTCASE_NAME_LENGTH: usize = 16;
|
||||||
|
|
||||||
/// The name of an external is either a reference to a user-defined symbol
|
/// The name of an external is either a reference to a user-defined symbol
|
||||||
/// table, or a short sequence of ascii bytes so that test cases do not have
|
/// table, or a short sequence of ascii bytes so that test cases do not have
|
||||||
@@ -118,13 +118,13 @@ mod tests {
|
|||||||
assert_eq!(ExternalName::testcase("x").to_string(), "%x");
|
assert_eq!(ExternalName::testcase("x").to_string(), "%x");
|
||||||
assert_eq!(ExternalName::testcase("x_1").to_string(), "%x_1");
|
assert_eq!(ExternalName::testcase("x_1").to_string(), "%x_1");
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
ExternalName::testcase("long123456").to_string(),
|
ExternalName::testcase("longname12345678").to_string(),
|
||||||
"%long123456"
|
"%longname12345678"
|
||||||
);
|
);
|
||||||
// Constructor will silently drop bytes beyond the 10th
|
// Constructor will silently drop bytes beyond the 16th
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
ExternalName::testcase("long1234567").to_string(),
|
ExternalName::testcase("longname123456789").to_string(),
|
||||||
"%long123456"
|
"%longname12345678"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user