]> git.proxmox.com Git - pve-installer.git/blobdiff - proxmox-installer-common/src/utils.rs
fqdn comparison: expand test scope
[pve-installer.git] / proxmox-installer-common / src / utils.rs
index ddfd7a1e725317bba196ce22dd60160dd206752c..8d320759b518d309307ad853c73592fe128456da 100644 (file)
@@ -338,7 +338,11 @@ mod tests {
 
     #[test]
     fn fqdn_compare() {
+        assert_eq!(Fqdn::from("example.com"), Fqdn::from("example.com"));
         assert_eq!(Fqdn::from("example.com"), Fqdn::from("ExAmPle.Com"));
         assert_eq!(Fqdn::from("ExAmPle.Com"), Fqdn::from("example.com"));
+        assert_ne!(Fqdn::from("subdomain.ExAmPle.Com"), Fqdn::from("example.com"));
+        assert_ne!(Fqdn::from("foo.com"), Fqdn::from("bar.com"));
+        assert_ne!(Fqdn::from("example.com"), Fqdn::from("example.net"));
     }
 }