コード例 #1
0
 /// <summary>
 /// The method that verifies the arguments of called methods using NFluent
 /// </summary>
 /// <typeparam name="T">type of arguments to verify</typeparam>
 /// <param name="check">delegate that contains assertion</param>
 /// <returns>parameter of called method</returns>
 public static T Me <T>(Func <T, ICheckLink <ICheck <T> > > check)
 {
     return(ArgumentMatcher.Enqueue(new NFluentMatcherAdapter <T>(check)));
 }
コード例 #2
0
ファイル: Verify.cs プロジェクト: aelfa/trash-updater
 public static T That <T>(Action <T> action)
 {
     return(ArgumentMatcher.Enqueue(new AssertionMatcher <T>(action)));
 }
コード例 #3
0
 public static int Arg() => ArgumentMatcher.Enqueue(new IsFortyTwo());
コード例 #4
0
 /// <summary>
 /// The method that verifies the arguments of called methods using FluentAssertions
 /// </summary>
 /// <typeparam name="T">type of arguments to verify</typeparam>
 /// <param name="action">delegate that contains assertion</param>
 /// <returns>parameter of called method</returns>
 public static T That <T>(Action <T> action)
 {
     return(ArgumentMatcher.Enqueue(new FluentAssertionsMatcherAdapter <T>(action)));
 }
コード例 #5
0
 public static ref IEnumerable <T> IsCollectionEquivalentTo <T>(T[] values,
                                                                Func <EquivalencyAssertionOptions <T>, EquivalencyAssertionOptions <T> > configure) =>
 ref ArgumentMatcher.Enqueue(new CollectionEquivalencyMatcher <T>(values, configure));
コード例 #6
0
 public static ref T IsEquivalentTo <T>(T value,
                                        Func <EquivalencyAssertionOptions <T>, EquivalencyAssertionOptions <T> > configure) =>
 ref ArgumentMatcher.Enqueue(new EquivalencyArgumentMatcher <T>(value, configure));