public virtual void test_resolve_oneLeg()
        {
            IborCapFloor         @base = IborCapFloor.of(CAPFLOOR_LEG);
            ResolvedIborCapFloor test  = @base.resolve(REF_DATA);

            assertEquals(test.CapFloorLeg, CAPFLOOR_LEG.resolve(REF_DATA));
            assertEquals(test.PayLeg.Present, false);
        }
        public virtual void test_resolve_twoLegs()
        {
            IborCapFloor         @base = IborCapFloor.of(CAPFLOOR_LEG, PAY_LEG);
            ResolvedIborCapFloor test  = @base.resolve(REF_DATA);

            assertEquals(test.CapFloorLeg, CAPFLOOR_LEG.resolve(REF_DATA));
            assertEquals(test.PayLeg.get(), PAY_LEG.resolve(REF_DATA));
        }
Ejemplo n.º 3
0
        //-------------------------------------------------------------------------
        public virtual void test_resolve()
        {
            IborCapFloorTrade         test     = sut();
            ResolvedIborCapFloorTrade expected = ResolvedIborCapFloorTrade.builder().info(TRADE_INFO).product(PRODUCT.resolve(REF_DATA)).premium(PREMIUM.resolve(REF_DATA)).build();

            assertEquals(test.resolve(REF_DATA), expected);
        }