internal static InterpolatedNodalCurveDefinition fraSwapCurveDefinition()
        {
            string fra3x6 = "fra3x6";
            string fra6x9 = "fra6x9";
            string swap1y = "swap1y";
            string swap2y = "swap2y";
            string swap3y = "swap3y";

            FraCurveNode           fra3x6Node = CurveTestUtils.fraNode(3, fra3x6);
            FraCurveNode           fra6x9Node = CurveTestUtils.fraNode(6, fra6x9);
            FixedIborSwapCurveNode swap1yNode = fixedIborSwapNode(Tenor.TENOR_1Y, swap1y);
            FixedIborSwapCurveNode swap2yNode = fixedIborSwapNode(Tenor.TENOR_2Y, swap2y);
            FixedIborSwapCurveNode swap3yNode = fixedIborSwapNode(Tenor.TENOR_3Y, swap3y);

            CurveName         curveName = CurveName.of("FRA and Fixed-Float Swap Curve");
            IList <CurveNode> nodes     = ImmutableList.of(fra3x6Node, fra6x9Node, swap1yNode, swap2yNode, swap3yNode);

            return(InterpolatedNodalCurveDefinition.builder().name(curveName).xValueType(ValueType.YEAR_FRACTION).yValueType(ValueType.ZERO_RATE).dayCount(DayCounts.ACT_ACT_ISDA).nodes(nodes).interpolator(CurveInterpolators.DOUBLE_QUADRATIC).extrapolatorLeft(CurveExtrapolators.FLAT).extrapolatorRight(CurveExtrapolators.FLAT).build());
        }
        /// <summary>
        /// Tests that par rates and ibor index are required for curves.
        /// </summary>
        public virtual void requirements()
        {
            FraCurveNode      node1x4   = CurveTestUtils.fraNode(1, "foo");
            FraCurveNode      node2x5   = CurveTestUtils.fraNode(2, "foo");
            IList <CurveNode> nodes     = ImmutableList.of(node1x4, node2x5);
            CurveGroupName    groupName = CurveGroupName.of("Curve Group");
            CurveName         curveName = CurveName.of("FRA Curve");
            ObservableSource  obsSource = ObservableSource.of("Vendor");

            InterpolatedNodalCurveDefinition curveDefn = InterpolatedNodalCurveDefinition.builder().name(curveName).nodes(nodes).interpolator(CurveInterpolators.DOUBLE_QUADRATIC).extrapolatorLeft(CurveExtrapolators.FLAT).extrapolatorRight(CurveExtrapolators.FLAT).build();

            RateIndex ibor = IborIndices.USD_LIBOR_3M;
            RatesCurveGroupDefinition groupDefn = RatesCurveGroupDefinition.builder().name(groupName).addCurve(curveDefn, Currency.USD, ibor).build();

            MarketDataConfig marketDataConfig = MarketDataConfig.builder().add(groupName, groupDefn).build();

            RatesCurveGroupMarketDataFunction function = new RatesCurveGroupMarketDataFunction();
            RatesCurveGroupId      curveGroupId        = RatesCurveGroupId.of(groupName, obsSource);
            MarketDataRequirements requirements        = function.requirements(curveGroupId, marketDataConfig);

            assertThat(requirements.NonObservables).contains(RatesCurveInputsId.of(groupName, curveName, obsSource));
            assertThat(requirements.TimeSeries.contains(IndexQuoteId.of(ibor)));
        }