Package test.saaj

Examples of test.saaj.TestAttachment$Src


   */
  @Test
  public void testDeepMapping_UsingCustomGetSetMethods() {
    mapper = super.getMapper(new String[] { "deepMappingUsingCustomGetSet.xml" });

    Src src = newInstance(Src.class);
    src.setSrcField("srcFieldValue");

    Dest dest = mapper.map(src, Dest.class);

    assertNotNull(dest.getDestField().getNestedDestField().getNestedNestedDestField());
    assertEquals(src.getSrcField(), dest.getDestField().getNestedDestField().getNestedNestedDestField());
    assertTrue("should have been set by customer setter method", dest.getDestField().getNestedDestField().isSetWithCustomMethod());

    Src dest2 = mapper.map(dest, Src.class);

    assertNotNull(dest2.getSrcField());
    assertEquals(dest.getDestField().getNestedDestField().getNestedNestedDestField(), dest2.getSrcField());
  }
View Full Code Here


   */
  @Test
  public void testDeepMapping_UsingCustomGetSetMethods() {
    mapper = super.getMapper(new String[] { "deepMappingUsingCustomGetSet.xml" });

    Src src = newInstance(Src.class);
    src.setSrcField("srcFieldValue");

    Dest dest = mapper.map(src, Dest.class);

    assertNotNull(dest.getDestField().getNestedDestField().getNestedNestedDestField());
    assertEquals(src.getSrcField(), dest.getDestField().getNestedDestField().getNestedNestedDestField());
    assertTrue("should have been set by customer setter method", dest.getDestField().getNestedDestField().isSetWithCustomMethod());

    Src dest2 = mapper.map(dest, Src.class);

    assertNotNull(dest2.getSrcField());
    assertEquals(dest.getDestField().getNestedDestField().getNestedNestedDestField(), dest2.getSrcField());
  }
View Full Code Here

TOP

Related Classes of test.saaj.TestAttachment$Src

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.