0
我有一個套件,有多個類的測試。我需要多次運行這個套件(不是並行的)。換句話說,運行「FirefoxTests」測試300次,或1000次等。我知道如何使用junit來做到這一點,但我沒有使用我的腳本現在已經轉換到的testng。這裏是我的xml文件:testng多次運行硒測試
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="SuiteEndToEnd" parallel="false" verbose="10" thread-count="2">
<listeners>
<listener class-name="com.bpms.tests.MySuiteListener"/>
</listeners>
<test name="FirefoxTests">
<parameter name="browser" value="firefox"/>
<classes>
<class name="com.bpms.tests.InitiateBuyPlan"/>
<class name="com.bpms.tests.AddItemsToBuyPlan"/>
<class name="com.bpms.tests.ReviewBuyPlan"/>
<class name="com.bpms.tests.ApproveBuyPlan"/>
<class name="com.bpms.tests.ManageQuoteSolicitation"/>
<class name="com.bpms.tests.StartQuote"/>
<class name="com.bpms.tests.ReviewQuote"/>
<class name="com.bpms.tests.RecordInterestInQuotes"/>
<class name="com.bpms.tests.ReviewCountryBuyIn"/>
<class name="com.bpms.tests.CompleteItemInfo"/>
<class name="com.bpms.tests.ReviewItemInformation"/>
<class name="com.bpms.tests.UpdateInterestInQuote"/>
<class name="com.bpms.tests.PerformLogisticsAnalysis"/>
<class name="com.bpms.tests.SecondReview"/>
<class name="com.bpms.tests.ReviewNLCDiagrams"/>
<class name="com.bpms.tests.ConfirmItemSpecifications"/>
<class name="com.bpms.tests.ClassifyItem"/>
<class name="com.bpms.tests.ApproveItem" />
<class name="com.bpms.tests.ClassifyItem2"/>
<class name="com.bpms.tests.CompleteItemClassification"/>
<class name="com.bpms.tests.ApproveItemClassification"/>
<class name="com.bpms.tests.SubmitLinkToFreightEstimates"/>
<class name="com.bpms.tests.ReviewFreightWorksheet"/>
<class name="com.bpms.tests.ReviewItemInfoAndReviseInterest"/>
<class name="com.bpms.tests.ManageAnalyzedQuotes"/>
<class name="com.bpms.tests.AuthorizeItemDevelopment"/>
<class name="com.bpms.tests.ConsolidateCountryAuthorizations"/>
<class name="com.bpms.tests.FinalizeItemInformationAndGenerateUnsignedItemAgreementPDF"/>
<class name="com.bpms.tests.VerifyAndUploadItemDocuments"/>
<class name="com.bpms.tests.AttachDocsForApproval"/>
<class name="com.bpms.tests.FinalizeItemForApproval"/>
<class name="com.bpms.tests.ApproveItemGMM"/>
<class name="com.bpms.tests.ConsolidateInCountryAGMM_GMMResponses"/>
<class name="com.bpms.tests.InitiateCodeOfConductForFactory"/>
<class name="com.bpms.tests.SubmitAuditResultsForFactory"/>
<class name="com.bpms.tests.ConfirmItemSetupAndPOsIssued"/>
<class name="com.bpms.tests.VerifyReceiptsOfPOs"/>
<class name="com.bpms.tests.ConfirmReceiptOfPOs"/>
<class name="com.bpms.tests.ReviewQAProductionTestResults"/>
<class name="com.bpms.tests.CompleteProjectChecklist"/>
<class name="com.bpms.tests.VerifySupplierCodeOfConductForFactory"/>
<class name="com.bpms.tests.VerifyChainSecurityForFactory"/>
</classes>
</test> <!-- FirefoxTests -->
</suite> <!-- SuiteEndToEnd -->