mirror of
https://github.com/htrefil/rkvm.git
synced 2024-12-26 09:58:32 +01:00
Add example config tests
This commit is contained in:
parent
e46d14bb14
commit
1c148cf3a3
2 changed files with 17 additions and 0 deletions
|
@ -119,4 +119,10 @@ mod tests {
|
|||
|
||||
assert_eq!(parsed_ip, Ipv6Addr::from_str("::1").unwrap());
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn example_parses() {
|
||||
let config = include_str!("../../example/client.toml");
|
||||
toml::from_str::<Config>(config).unwrap();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1226,3 +1226,14 @@ impl Into<Key> for SwitchKey {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod test {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn example_parses() {
|
||||
let config = include_str!("../../example/server.toml");
|
||||
toml::from_str::<Config>(config).unwrap();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue