4using System.Collections.Generic;
12 public static readonly IEnumerable<Tuple<Func<Specification, bool>,
string>>
Lookup =
13 new List<Tuple<Func<Specification, bool>,
string>>
16 "Scalar option specifications do not support range specification."
20 "Zero is not allowed in range of sequence option specifications."
27 return spec => spec.TargetType == TargetType.Scalar && (spec.Min.IsJust() || spec.Max.IsJust());
32 return spec => spec.TargetType == TargetType.Sequence && spec.HavingRange((min, max) => min > max);
43 spec.TargetType == TargetType.Sequence &&
44 (spec.HavingMin(min => min == 0) || spec.HavingMax(max => max == 0));
static readonly IEnumerable< Tuple< Func< Specification, bool >, string > > Lookup
static Func< Specification, bool > GuardAgainstScalarWithRange()
static Func< Specification, bool > GuardAgainstOneCharLongName()
static Func< Specification, bool > GuardAgainstSequenceWithWrongRange()
static Func< Specification, bool > GuardAgainstSequenceWithZeroRange()