Package org.testng.xml.internal
Class XmlSuiteUtils
java.lang.Object
org.testng.xml.internal.XmlSuiteUtils
A utility class to work with
XmlSuite-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidEnsure that two XmlSuite don't have the same nameprivate static voidadjustSuiteNamesToEnsureUniqueness(List<XmlSuite> suites, Set<String> names) constructXmlClassesUsing(List<String> classes) (package private) static voidensureNoDuplicateTestsArePresent(XmlSuite xmlSuite) Ensures that the current suite doesn't contain any duplicateXmlTestinstances.static XmlSuitenewXmlSuiteUsing(List<String> classes) static voidA validator that runs through the list of suites and checks if each of the suites contains anyXmlTestwith the same name.
-
Constructor Details
-
XmlSuiteUtils
private XmlSuiteUtils()
-
-
Method Details
-
validateIfSuitesContainDuplicateTests
A validator that runs through the list of suites and checks if each of the suites contains anyXmlTestwith the same name. If found, then aTestNGExceptionis raised.- Parameters:
suites- - The list ofXmlSuiteto validate.
-
adjustSuiteNamesToEnsureUniqueness
Ensure that two XmlSuite don't have the same name- Parameters:
suites- - The List ofXmlSuitethat are to be tested and names updated if duplicate names found.
-
newXmlSuiteUsing
-
ensureNoDuplicateTestsArePresent
Ensures that the current suite doesn't contain any duplicateXmlTestinstances. If duplicates are found, then aTestNGExceptionis raised.- Parameters:
xmlSuite- - TheXmlSuiteto work with.
-
constructXmlClassesUsing
-
adjustSuiteNamesToEnsureUniqueness
-