Class XMLObjectProviderBaseTestCase


public abstract class XMLObjectProviderBaseTestCase extends XMLObjectBaseTestCase
Base test case for XMLObjects in XMLTooling for which we need a full set of object provider tests, i.e marshalling and unmarshalling of single elements; with optional attributes; and with child elements.
  • Field Details

    • singleElementFile

      protected String singleElementFile
      Location of file containing a single element with NO optional attributes.
    • singleElementOptionalAttributesFile

      protected String singleElementOptionalAttributesFile
      Location of file containing a single element with all optional attributes.
    • singleElementUnknownAttributesFile

      protected String singleElementUnknownAttributesFile
      Location of file containing a single element with some unknown attributes.
    • childElementsFile

      protected String childElementsFile
      Location of file containing a single element with child elements.
    • invalidFile

      protected String invalidFile
      Location of file containing some kind of invalid content.
    • expectedDOM

      protected Document expectedDOM
      The expected result of a marshalled single element with no optional attributes.
    • expectedOptionalAttributesDOM

      protected Document expectedOptionalAttributesDOM
      The expected result of a marshalled single element with all optional attributes.
    • expectedUnknownAttributesDOM

      protected Document expectedUnknownAttributesDOM
      The expected result of a marshalled single element some unknown attributes.
    • expectedChildElementsDOM

      protected Document expectedChildElementsDOM
      The expected result of a marshalled single element with child elements.
    • invalidDOM

      protected Document invalidDOM
      The result of parsing the invalid file.
  • Constructor Details

    • XMLObjectProviderBaseTestCase

      public XMLObjectProviderBaseTestCase()
  • Method Details

    • initXMLObjectProviderTestingSupprt

      @BeforeClass protected void initXMLObjectProviderTestingSupprt() throws Exception
      Init testing fields.
      Throws:
      Exception - on error
    • testSingleElementUnmarshall

      public abstract void testSingleElementUnmarshall()
      Tests unmarshalling a document that contains a single element (no children) with no optional attributes.
    • testSingleElementOptionalAttributesUnmarshall

      public void testSingleElementOptionalAttributesUnmarshall()
      Tests unmarshalling a document that contains a single element (no children) with all that element's optional attributes.
    • testSingleElementUnknownAttributesUnmarshall

      public void testSingleElementUnknownAttributesUnmarshall()
      Tests unmarshalling a document that contains a single element (no children) with all that element's optional attributes.
    • testChildElementsUnmarshall

      public void testChildElementsUnmarshall()
      Tests unmarshalling a document that contains a single element with children.
    • testSingleElementMarshall

      public abstract void testSingleElementMarshall()
      Tests marshalling the contents of a single element, with no optional attributes, to a DOM document.
    • testSingleElementOptionalAttributesMarshall

      public void testSingleElementOptionalAttributesMarshall()
      Tests marshalling the contents of a single element, with all optional attributes, to a DOM document.
    • testSingleElementUnknownAttributesMarshall

      public void testSingleElementUnknownAttributesMarshall()
      Tests marshalling the contents of a single element, some unknown attributes, to a DOM document.
    • testChildElementsMarshall

      public void testChildElementsMarshall()
      Tests marshalling the contents of a single element with child elements to a DOM document.
    • testAttributeIDnessMarshall

      public void testAttributeIDnessMarshall(@Nonnull XMLObject target, String idValue) throws MarshallingException, XMLParserException
      Test marshalling of attribute IDness.
      Parameters:
      target - target object
      idValue - ID value
      Throws:
      MarshallingException
      XMLParserException