mirror of
https://github.com/EasyTier/EasyTier.git
synced 2026-08-07 04:59:49 +00:00
config: update test for policies
This commit is contained in:
@@ -272,6 +272,12 @@ mod tests {
|
||||
name = "et-test"
|
||||
domain = "测试.net"
|
||||
|
||||
["top".import]
|
||||
whitelist = ["*"]
|
||||
blacklist = []
|
||||
disabled = true
|
||||
recursive = true
|
||||
|
||||
[[zone]]
|
||||
origin = "et.top"
|
||||
|
||||
@@ -282,8 +288,6 @@ mod tests {
|
||||
[[zone]]
|
||||
origin = "google.com"
|
||||
|
||||
broadcast = true
|
||||
|
||||
ttl = 10
|
||||
|
||||
records = [
|
||||
@@ -297,6 +301,8 @@ mod tests {
|
||||
"10.175.160.10",
|
||||
]
|
||||
|
||||
[zone.export]
|
||||
|
||||
"#;
|
||||
|
||||
#[tokio::test]
|
||||
@@ -325,7 +331,7 @@ mod tests {
|
||||
.extract_if(.., |z| z.origin.to_string() == "google.com")
|
||||
.next()
|
||||
.unwrap();
|
||||
assert_eq!(zone.broadcast, true);
|
||||
assert_eq!(zone.policy.export.is_some(), true);
|
||||
let zone = ZoneConfigPb::from(&zone);
|
||||
println!("{}", sep);
|
||||
println!("{}", zone);
|
||||
|
||||
Reference in New Issue
Block a user