mirror of
https://github.com/sharkdp/bat.git
synced 2025-01-15 01:58:23 +01:00
Fix tests
1. for override test, test for something in `common` 2. move git mappings to `common`
This commit is contained in:
parent
22531eab90
commit
1f10d846a3
@ -153,13 +153,13 @@ mod tests {
|
|||||||
let mut map = SyntaxMapping::new();
|
let mut map = SyntaxMapping::new();
|
||||||
|
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
map.get_syntax_for("/etc/profile"),
|
map.get_syntax_for("/path/to/httpd.conf"),
|
||||||
Some(MappingTarget::MapTo("Bourne Again Shell (bash)"))
|
Some(MappingTarget::MapTo("Apache Conf"))
|
||||||
);
|
);
|
||||||
map.insert("/etc/profile", MappingTarget::MapTo("My Syntax"))
|
map.insert("httpd.conf", MappingTarget::MapTo("My Syntax"))
|
||||||
.ok();
|
.ok();
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
map.get_syntax_for("/etc/profile"),
|
map.get_syntax_for("/path/to/httpd.conf"),
|
||||||
Some(MappingTarget::MapTo("My Syntax"))
|
Some(MappingTarget::MapTo("My Syntax"))
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user