blob: 38ebfdcccfffc3a1b8e4f2531558f078c0dce649 [file] [log] [blame]
package org.testng.xml;
import org.testng.TestNGException;
import org.xml.sax.SAXException;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
public class SuiteXmlParser extends XMLParser<XmlSuite> {
@Override
public XmlSuite parse(String currentFile, InputStream inputStream, boolean loadClasses) {
TestNGContentHandler contentHandler = new TestNGContentHandler(currentFile, loadClasses);
try {
parse(inputStream, contentHandler);
return contentHandler.getSuite();
} catch (SAXException | IOException e) {
throw new TestNGException(e);
}
}
}