Package org.apache.axiom.truth.xml
Class XMLTruth
java.lang.Object
org.apache.axiom.truth.xml.XMLTruth
Google Truth extension for XML.
-
Method Summary
Modifier and TypeMethodDescriptionstatic com.google.common.truth.Subject.Factory<XMLSubject,Object> xml()Get theSubject.Factoryto be used withTruth.assertAbout(Subject.Factory).static <T> ObjectPrepare XML data so that it will be accessed through a particular API.
-
Method Details
-
xml
Get theSubject.Factoryto be used withTruth.assertAbout(Subject.Factory).- Returns:
- a
Subject.FactoryforXMLSubjectinstances
-
xml
Prepare XML data so that it will be accessed through a particular API. Use this method for objects that represent XML data, but that implement more than one API supported by the factory returned byxml()(e.g. DOM and the Axiom API).- Parameters:
type- the API to use (e.g.Documentobject- an object implementing that API- Returns:
- an object that can be passed to
SimpleSubjectBuilder.that(Object)orXMLSubject.hasSameContentAs(Object)
-