You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
aochsner edited this page May 21, 2012
·
2 revisions
#AnyOf
Matches if any of its sub-matchers do:
[Test]publicvoidAnyOf(){varcontainsCat=Contains.String("cat");varcontainsJohn=Contains.String("john");varmatchesAnyOf=newAnyOf(new[]{containsCat,containsJohn});conststringactual="the cat sat on the mat";Assert.That(actual,matchesAnyOf);// or alternativelyAssert.That(actual,Matches.AnyOf(containsCat,containsJohn));}