Пример #1
0
        public static void That(object objA, IPerformAComparison comparison)
        {
            var success = comparison.Execute(objA);

            if (!success)
            {
                throw comparison.GenerateError(objA);
            }
        }
Пример #2
0
 public IPerformAComparison Shim(IPerformAComparison comparison)
 {
     return _comparisonSettings == ComparisonSettings.Negated
         ? new Invert(comparison)
         : comparison;
 }
Пример #3
0
 public static void That(object objA, IPerformAComparison comparison)
 {
     var success = comparison.Execute(objA);
     if (!success)
     {
         throw comparison.GenerateError(objA);
     }
 }
Пример #4
0
 public Invert(IPerformAComparison regular)
 {
     _regular = regular;
 }
Пример #5
0
 public IPerformAComparison Shim(IPerformAComparison comparison)
 {
     return(_comparisonSettings == ComparisonSettings.Negated
         ? new Invert(comparison)
         : comparison);
 }
Пример #6
0
 public Invert(IPerformAComparison regular)
 {
     _regular = regular;
 }