Add Spanish, Italian and Russian; dropdown order and language file tests
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
6629472811
commit
a13abf63f3
6 files changed
+3112
-7
No files matched your search
+9
-1
@@ -2189,7 +2189,15 @@ mod font_tests {
|
||||
let (_, map) = load_font();
|
||||
let question = font_src(&map, '?');
|
||||
let mut missing = std::collections::BTreeSet::new();
|
||||
for file in [include_str!("../lang/en.lang"), include_str!("../lang/de.lang")] {
|
||||
// every language file in lang/
|
||||
let files: Vec<String> = std::fs::read_dir("lang")
|
||||
.expect("lang directory")
|
||||
.filter_map(|e| e.ok())
|
||||
.filter(|e| e.path().extension().map_or(false, |x| x == "lang"))
|
||||
.map(|e| std::fs::read_to_string(e.path()).expect("language file"))
|
||||
.collect();
|
||||
assert!(files.len() >= 2);
|
||||
for file in &files {
|
||||
for ch in file.chars().filter(|c| !c.is_control() && *c != ' ') {
|
||||
if ch != '?' && font_src(&map, ch) == question {
|
||||
missing.insert(ch);
|
||||
|
||||
Reference in new issue
Block a user