public static IAssert <T> Fulfills <T, TMember>( this IAssertMember <T, TMember> member, Func <IAssert <TMember>, IAssert <TMember> > assertion) { return (member.SetAssertion( new AssertToAssertValueAdapter <TMember>(assertion(new ObjectAssertion <TMember>())))); }
public static IAssert <T> IsEqualTo <T, TItem>(this IAssertMember <T, IList <TItem> > member, IList <TItem> expectedItems) { return(member.SetAssertion(new Assertions.MemberAssertions.Lists.EqualAssertion <TItem>(expectedItems))); }
public static IAssert <T> FulfilAll <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, Expression <Func <TElement, bool> > expected) { return(member.SetAssertion(new AllFulfilPredicateAssertion <TElement>(expected))); }
public static IAssert <T> HasNonePredicate <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, Expression <Func <TElement, bool> > predicate) { return(member.SetAssertion(new NoneFulfilsPredicateAssertion <TElement>(predicate))); }
public static IAssert <T> DoesntContain <T, TItem>(this IAssertMember <T, IEnumerable <TItem> > member, params TItem[] expectedItems) { return(member.SetAssertion(new ContainsNotAssertion <TItem>(expectedItems))); }
public static IAssert <T> ContainsInOrder <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, IList <TElement> expectedElements) { return(member.SetAssertion(new ContainsInOrderAssertion <TElement>(expectedElements))); }
public static IAssert <T> HasAny <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, params Func <IAssert <TElement>, IAssert <TElement> >[] assertions) { return(member.SetAssertion(new HasAnyMultipleAssertion <TElement>(assertions.Map(assertion => assertion(new ObjectAssertion <TElement>()))))); }
public static IAssert <T> StartsWith <T>(this IAssertMember <T, string> member, string expectedStart) { return(member.SetAssertion(new StartsWithAssertion(expectedStart))); }
public static IAssert <T> DoesntEndWith <T>(this IAssertMember <T, string> member, string expected) { return(member.SetAssertion(new EndsNotWithAssertion(expected))); }
public static IAssert <T> IsEqualTo <T>(this IAssertMember <T, string> member, string expected) { return(member.SetAssertion(new EqualAssertion(expected))); }
public static IAssert <T> HasLength <T>(this IAssertMember <T, string> member, int expectedLength) { return(member.SetAssertion(new HasLengthAssertion(expectedLength))); }
public static IAssert <T> IsNull <T, TMember>(this IAssertMember <T, TMember> member) where TMember : class { return(member.SetAssertion(new IsNullAssertion <TMember>())); }
public static IAssert <T> IsEqualToAny <T, TMember>(this IAssertMember <T, TMember> member, params TMember[] expectedValues) { return(member.SetAssertion(new IsEqualToAnyAssertion <TMember>(expectedValues))); }
public static IAssert <T> Printout <T, TMember>(this IAssertMember <T, TMember> member) { return(member.SetAssertion(new PrintoutAssertion <TMember>())); }
public static IAssert <T> IsPositive <T>(this IAssertMember <T, TimeSpan> member) { return(member.SetAssertion(new IsPositiveAssertion())); }
public static IAssert <T> DoesntContain <T>(this IAssertMember <T, string> member, string expected) { return(member.SetAssertion(new ContainsNotAssertion(expected))); }
public static IAssert <T> IsSubsetOf <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, IEnumerable <TElement> expectedSuperset) { return(member.SetAssertion(new IsSubsetOfAssertion <TElement>(expectedSuperset))); }
public static IAssert <T> IsNull <T>(this IAssertMember <T, string> member) { return(member.SetAssertion(new IsNullAssertion())); }
public static IAssert <T> IsNotEmpty <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member) { return(member.SetAssertion(new IsNotEmptyAssertion <TElement>())); }
public static IAssert <T> IsInRange <T, TMember>(this IAssertMember <T, TMember> member, TMember min, TMember max) where TMember : IComparable <TMember> { return(member.SetAssertion(new InRangeAssertion <TMember>(min, max))); }
public static IAssert <T> HasNone <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, Func <IAssert <TElement>, IAssert <TElement> > assertion) { return(member.SetAssertion(new HasNoneAssertion <TElement>(assertion(new ObjectAssertion <TElement>())))); }
public static IAssert <T> IsGreaterOrEqualTo <T, TMember>(this IAssertMember <T, TMember> member, TMember expected) where TMember : IComparable <TMember> { return(member.SetAssertion(new GreaterOrEqualAssertion <TMember>(expected))); }
public static IAssert <T> HasCount <T, TMember>(this IAssertMember <T, IEnumerable <TMember> > member, int expected) { return(member.SetAssertion(new HasCountAssertion <TMember>(expected))); }
public static IAssert <T> IsLessThan <T, TMember>(this IAssertMember <T, TMember> member, TMember expected) where TMember : IComparable <TMember> { return(member.SetAssertion(new LessThanAssertion <TMember>(expected))); }
public static IAssert <T> DoesntContainNulls <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member) { return(member.SetAssertion(new ContainsNoNullsAssertion <TElement>())); }
public static IAssert <T> IsNotEqualTo <T>(this IAssertMember <T, TimeSpan> member, TimeSpan expected) { return(member.SetAssertion(new NotEqualAssertion <TimeSpan>(expected))); }
public static IAssert <T> IsEquivalentTo <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, IEnumerable <TElement> expected) { return(member.SetAssertion(new EquivalentAssertion <TElement>(expected))); }
public static IAssert <T> IsCloseTo <T>(this IAssertMember <T, TimeSpan> member, TimeSpan expected, TimeSpan range) { return(member.SetAssertion(new IsCloseToAssertion(expected, range))); }
public static IAssert <T> EndsWith <T, TElement>(this IAssertMember <T, IEnumerable <TElement> > member, TElement expected) { return(member.SetAssertion(new EndsWithAssertion <TElement>(expected))); }
public static IAssert <T> IsEqualTo <T, TMember>(this IAssertMember <T, TMember> member, TMember expected) { return(member.SetAssertion(new EqualAssertion <TMember>(expected))); }