public void TestUpdateAD() { var actual = new XAD(this.genericMessage); NotifierBase.UpdateAD(entityAddress, actual); Assert.AreEqual("Hamilton", actual.City.Value); Assert.AreEqual("Canada", actual.Country.Value); Assert.AreEqual("L8N3T2", actual.ZipOrPostalCode.Value); Assert.AreEqual("Ontario", actual.StateOrProvince.Value); Assert.AreEqual("123 Main street west", actual.StreetAddress.Value); }
public void TestUpdateADCityOnly() { var actual = new XAD(this.genericMessage); this.entityAddress.Component = new List <EntityAddressComponent> { new EntityAddressComponent(AddressComponentKeys.City, "Hamilton") }; NotifierBase.UpdateAD(entityAddress, actual); Assert.AreEqual("Hamilton", actual.City.Value); Assert.AreEqual(string.Empty, actual.Country.Value); Assert.AreEqual(string.Empty, actual.ZipOrPostalCode.Value); Assert.AreEqual(string.Empty, actual.StateOrProvince.Value); Assert.AreEqual(string.Empty, actual.StreetAddress.Value); }