public void It_can_get_and_set_BoundObjectType() { // Act var testObjectTypeDescription = new ObjectTypeDescription { DisplayName = "Test ObjectTypeDescription" }; _it.BoundObjectType = testObjectTypeDescription; // Assert Assert.AreEqual(testObjectTypeDescription.DisplayName, _it.BoundObjectType.DisplayName); }
public void It_has_a_constructor_that_takes_an_IdmResource_without_Creator() { var resource = new IdmResource { DisplayName = "My Display Name", }; var it = new ObjectTypeDescription(resource); Assert.AreEqual("My Display Name", it.DisplayName); Assert.IsNull(it.Creator); }
public void It_can_get_and_set_msidmTargetObjectTypeIdentifier() { // Act var testObjectTypeDescription = new ObjectTypeDescription { DisplayName = "Test ObjectTypeDescription" }; _it.msidmTargetObjectTypeIdentifier = testObjectTypeDescription; // Assert Assert.AreEqual(testObjectTypeDescription.DisplayName, _it.msidmTargetObjectTypeIdentifier.DisplayName); }
public void It_has_a_constructor_that_takes_an_IdmResource() { var resource = new IdmResource { DisplayName = "My Display Name", Creator = new Person { DisplayName = "Creator Display Name", ObjectID = "Creator ObjectID"}, }; var it = new ObjectTypeDescription(resource); Assert.AreEqual("ObjectTypeDescription", it.ObjectType); Assert.AreEqual("My Display Name", it.DisplayName); Assert.AreEqual("Creator Display Name", it.Creator.DisplayName); }
public void It_has_BoundObjectType_which_can_be_set_back_to_null() { // Arrange var testObjectTypeDescription = new ObjectTypeDescription { DisplayName = "Test ObjectTypeDescription" }; _it.BoundObjectType = testObjectTypeDescription; // Act _it.BoundObjectType = null; // Assert Assert.IsNull(_it.BoundObjectType); }
public void It_has_a_constructor_that_takes_an_IdmResource() { var resource = new IdmResource { DisplayName = "My Display Name", Creator = new Person { DisplayName = "Creator Display Name", ObjectID = "Creator ObjectID" }, }; var it = new ObjectTypeDescription(resource); Assert.AreEqual("ObjectTypeDescription", it.ObjectType); Assert.AreEqual("My Display Name", it.DisplayName); Assert.AreEqual("Creator Display Name", it.Creator.DisplayName); }
public void It_has_msidmTargetObjectTypeIdentifier_which_can_be_set_back_to_null() { // Arrange var testObjectTypeDescription = new ObjectTypeDescription { DisplayName = "Test ObjectTypeDescription" }; _it.msidmTargetObjectTypeIdentifier = testObjectTypeDescription; // Act _it.msidmTargetObjectTypeIdentifier = null; // Assert Assert.IsNull(_it.msidmTargetObjectTypeIdentifier); }
public ObjectTypeDescriptionTests() { _it = new ObjectTypeDescription(); }