public void Equals_InvalidCast() { // Arrange IConditionModifier modifier = new EqualsModifier<bool>(); // Act Action action = () => modifier.IsConditionMet(null, null); // Assert Assert.ThrowsException<InvalidCastException>(action); }
public void Equals_InvalidCast() { // Arrange IConditionModifier modifier = new EqualsModifier <bool>(); // Act Action action = () => modifier.IsConditionMet(null, null); // Assert Assert.ThrowsException <InvalidCastException>(action); }
public void Equals_True() { // Arrange bool result; IConditionModifier modifier = new EqualsModifier<UserInteractionMode>(); // Act result = modifier.IsConditionMet(UserInteractionMode.Mouse, UserInteractionMode.Mouse); // Assert Assert.IsTrue(result); }
public void Equals_False() { // Arrange bool result; IConditionModifier modifier = new EqualsModifier <UserInteractionMode>(); // Act result = modifier.IsConditionMet(UserInteractionMode.Mouse, UserInteractionMode.Touch); // Assert Assert.IsFalse(result); }
public void Equals_AllowNullValue_ConditionNotMet() { // Arrange bool result; IConditionModifier modifier = new EqualsModifier<bool>(); modifier.TreatNullAsConditionNotMet = true; // Act result = modifier.IsConditionMet(null, null); // Assert Assert.IsFalse(result); }
public void Equals_AllowNullValue_ConditionNotMet() { // Arrange bool result; IConditionModifier modifier = new EqualsModifier <bool>(); modifier.TreatNullAsConditionNotMet = true; // Act result = modifier.IsConditionMet(null, null); // Assert Assert.IsFalse(result); }