예제 #1
0
 public VerificationSetPlan(SetVerificationGrammar grammar, Section section, ISetMatcher matcher, ISetComparison comparison, IEnumerable <StepValues> expected, Cell[] cells, long maximumRuntimeInMilliseconds)
 {
     _grammar    = grammar;
     _section    = section;
     _matcher    = matcher;
     _comparison = comparison;
     _expected   = expected;
     _cells      = cells;
     _maximumRuntimeInMilliseconds = maximumRuntimeInMilliseconds;
 }
        /// <summary>
        /// Use this method if you want to explicitly customize the comparison cells
        /// with editors, defaults, headers, or selection lists
        /// </summary>
        /// <param name="configure"></param>
        /// <returns></returns>
        public SetVerificationGrammar Comparisons(Action <ObjectComparison <T> > configure)
        {
            var comparer = new ObjectComparison <T>(_dataSource);

            configure(comparer);

            var grammar = new SetVerificationGrammar(_title, _leafName, comparer);

            if (_ordered)
            {
                grammar.Ordered();
            }

            return(grammar);
        }