public void ItemIsPresent_WithEqualityComparer() { Func <string, string, bool> comparer = (expected, actual) => actual.Contains(expected); var anyOf = new AnyOfConstraint(new[] { "A", "B", "C" }).Using(comparer); Assert.That(anyOf.ApplyTo("1. A").Status, Is.EqualTo(ConstraintStatus.Success)); }
public void ItemIsPresent_IgnoreCase() { var anyOf = new AnyOfConstraint(new[] { "a", "B", "ab" }).IgnoreCase; Assert.That(anyOf.ApplyTo("AB").Status, Is.EqualTo(ConstraintStatus.Success)); }