Exemplo n.º 1
0
        //-------------------------------------------------------------------------
        public virtual void test_getters()
        {
            ResolvedBondFutureTrade test  = sut();
            BondFutureTrade         @base = BondFutureTradeTest.sut();

            assertEquals(test.TradedPrice.get(), TradedPrice.of(@base.Info.TradeDate.get(), @base.Price));
        }
Exemplo n.º 2
0
 public override bool Equals(object obj)
 {
     if (obj == this)
     {
         return(true);
     }
     if (obj != null && obj.GetType() == this.GetType())
     {
         ResolvedBondFutureTrade other = (ResolvedBondFutureTrade)obj;
         return(JodaBeanUtils.equal(info, other.info) && JodaBeanUtils.equal(product, other.product) && JodaBeanUtils.equal(quantity, other.quantity) && JodaBeanUtils.equal(tradedPrice, other.tradedPrice));
     }
     return(false);
 }
        //-------------------------------------------------------------------------
        public virtual void test_resolve()
        {
            ResolvedBondFutureTrade expected = ResolvedBondFutureTrade.builder().info(POSITION_INFO).product(PRODUCT.resolve(REF_DATA)).quantity(QUANTITY).build();

            assertEquals(sut().resolve(REF_DATA), expected);
        }
Exemplo n.º 4
0
        //-------------------------------------------------------------------------
        public virtual void test_resolve()
        {
            ResolvedBondFutureTrade expected = ResolvedBondFutureTrade.builder().info(TRADE_INFO).product(FUTURE.resolve(REF_DATA)).quantity(QUANTITY).tradedPrice(TradedPrice.of(TRADE_INFO.TradeDate.get(), PRICE)).build();

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