Package siena.base.test.model

Examples of siena.base.test.model.BigDecimalStringModelStringId


    bigdec2 = pm.getByKey(BigDecimalModelNoPrecisionStringId.class, bigdec.id);
    assertEquals(bigdec, bigdec2);
  }
 
  public void testBigDecimalString() {
    BigDecimalStringModelStringId bigdec =
      new BigDecimalStringModelStringId("test", new BigDecimal("123456789.0123456890"));
    pm.insert(bigdec);
   
    BigDecimalStringModelStringId bigdec2 = pm.getByKey(BigDecimalStringModelStringId.class, bigdec.id);
    assertEquals(bigdec, bigdec2);
   
    bigdec =
      new BigDecimalStringModelStringId(
          "test2",
          new BigDecimal("999999999.9999999999"));
    pm.insert(bigdec);
   
    bigdec2 = pm.getByKey(BigDecimalStringModelStringId.class, bigdec.id);
    assertEquals(bigdec, bigdec2);
   
    //-100.5
    bigdec =
      new BigDecimalStringModelStringId("test3", new BigDecimal("-100.5000000000"));
    pm.insert(bigdec);
   
    bigdec2 = pm.getByKey(BigDecimalStringModelStringId.class, bigdec.id);
    assertEquals(bigdec, bigdec2);
  }
View Full Code Here

TOP

Related Classes of siena.base.test.model.BigDecimalStringModelStringId

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.