Package ghidra.util.xml
Class XmlTestHelper
java.lang.Object
ghidra.util.xml.XmlTestHelper
-
Constructor Summary
ConstructorDescriptionXmlTestHelper
(String tmpDirPath) XmlTestHelper
(String tmpDirPath, GhidraProject gp) -
Method Summary
Modifier and TypeMethodDescriptionvoid
static void
assertXMLFilesEquals
(XmlPullParser expectedXMLParser, XmlPullParser testXMLParser) static void
assertXMLFilesEquals
(File expectedXMLFile, File testXMLFile) void
clearXml()
void
compareXml
(File file) boolean
containsXml
(String line) void
dispose()
getTempFile
(String name) getXmlParser
(String name) loadResourceProgram
(String programName) void
loadXmlResource
(Package pkg, String name) Read an XML file as a resource.void
-
Constructor Details
-
Method Details
-
dispose
public void dispose() -
add
-
loadXmlResource
Read an XML file as a resource.- Parameters:
pkg
- where resource residesname
- name of the resource that is in the given package- Throws:
IOException
- thrown if there was a problem accessing the xml resource.
-
getTempFile
-
getProject
-
compareXml
- Throws:
Exception
-
containsXml
-
printExpectedLines
public void printExpectedLines() -
getXmlParser
- Throws:
IOException
SAXException
-
clearXml
public void clearXml() -
loadResourceProgram
public Program loadResourceProgram(String programName) throws IOException, CancelledException, DuplicateNameException, InvalidNameException, VersionException -
assertXMLFilesEquals
public static void assertXMLFilesEquals(File expectedXMLFile, File testXMLFile) throws SAXException, IOException - Throws:
SAXException
IOException
-
assertXMLFilesEquals
public static void assertXMLFilesEquals(XmlPullParser expectedXMLParser, XmlPullParser testXMLParser)
-