Ejemplo n.º 1
0
 public void EqualsTest()
 {
     string name = "name";
     string hostname = "hostname";
     ushort port = 8080;
     string type = "type";
     Dictionary<string, string> TXTRecord = new Dictionary<string, string>() { { "key", "value" } };
     SDService service = new SDService(name, hostname, port, type, TXTRecord);
     SDService other = new SDService(name, hostname, port, type, TXTRecord);
     Assert.IsTrue(service.Equals(other));
     Assert.IsTrue(service.GetHashCode() == other.GetHashCode());
 }
Ejemplo n.º 2
0
 public void EqualsWithNullTest()
 {
     string name = "name";
     string hostname = "hostname";
     ushort port = 8080;
     string type = "type";
     Dictionary<string, string> TXTRecord = new Dictionary<string, string>() { { "key", "value" } };
     SDService service = new SDService(name, hostname, port, type, TXTRecord);
     Assert.IsFalse(service.Equals(null));
 }