Example #1
0
 public static IEnumerable<Warning> Of(YieldCurveKey key, ManageableYieldCurveSnapshot value)
 {
     return value.HaveOverrides() ? new Warning[] { new OverriddenYieldCurveDisappearingWarning(key) } : new Warning[] { };
 }
        private static void AssertSaneValue(ManageableYieldCurveSnapshot yieldCurveSnapshot)
        {
            Assert.NotNull(yieldCurveSnapshot);
            Assert.InRange(yieldCurveSnapshot.Values.Values.Count(), 2, 200);

            foreach (var valueSnapshot in yieldCurveSnapshot.Values)
            {
                foreach (var snapshot in valueSnapshot.Value)
                {
                    ValueAssertions.AssertSensibleValue(snapshot.Value.MarketValue);
                    Assert.Null(snapshot.Value.OverrideValue);
                }
            }
        }