Package com.bansheeproject.builder.entity.test

Examples of com.bansheeproject.builder.entity.test.ComplexWithPath


  }
 
 
  @Test
  public void testEmptyEntityWithPath() {
    ComplexWithPath complex = new ComplexWithPath();
   
    Parser parser = new Parser();
    String xml = parser.encode(complex);
    Assert.assertEquals("<complex/>", xml);
   
View Full Code Here


   
  }
 
  @Test
  public void testEmptyEntityWithPath2() {
    ComplexWithPath complex = new ComplexWithPath();
    complex.test = "new";
    Parser parser = new Parser();
    String xml = parser.encode(complex);
    Assert.assertEquals("<complex><test>new</test></complex>", xml);
   
View Full Code Here

 
  @Test
  public void testUnmarshallWithPath() {
    String xml = "<complex><test>testValue</test></complex>";
    Parser parser = new Parser();
    ComplexWithPath complexWithPath = (ComplexWithPath)parser.decode(xml, ComplexWithPath.class);
   
    Assert.assertNotNull(complexWithPath);
    Assert.assertEquals("testValue", complexWithPath.test);
   
   
View Full Code Here

  }
  @Test
  public void testUnmarshallWithSpacedXML() {
    String xml = "<complex>\n\t<test>testValue</test>\n</complex>";
    Parser parser = new Parser();
    ComplexWithPath complexWithPath = (ComplexWithPath)parser.decode(xml, ComplexWithPath.class);
   
    Assert.assertNotNull(complexWithPath);
    Assert.assertEquals("testValue", complexWithPath.test);
   
  }
View Full Code Here

 
  @Test
  public void testRespectXMLSpaces() {
    String xml = "<complex>\n\t<test>testValue  \n</test>\n</complex>";
    Parser parser = new Parser();
    ComplexWithPath complexWithPath = (ComplexWithPath)parser.decode(xml, ComplexWithPath.class);
   
    Assert.assertNotNull(complexWithPath);
    Assert.assertEquals("testValue  \n", complexWithPath.test);
  }
View Full Code Here

TOP

Related Classes of com.bansheeproject.builder.entity.test.ComplexWithPath

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.