-
Notifications
You must be signed in to change notification settings - Fork 0
Tutorial: Use mass test data
In some cases the same executable example has to be executed for a large number of datasets. Instead of doublicating this executable example for each data set, it is much more efficient to use parametrized tests and to store the test data in Excel files.
-
Open file "./sysnat.natural.language.executable.examples/ExecutableExamples/GoogleSearch/WebPageCheck.nlxx".
-
Dublicate an existing executable example and give the new executable example the name "Parametrized Web Page Check".
-
Replace line 'TestData: GoogleSearchSysNat' by the new line 'Test-Parameter: GoogleSearchMassData'.
-
Create new Excel file "./sysnat.natural.language.executable.examples/testdata/GoogleSearch/GoogleSearchMassData.xlsx".
-
Open excel file and enter the following data with the root cell at postition A1:
|root cell |SearchText |ExpectedSearchResultText1 |ExpectedSearchResultText2 | |GoogleSearchMassData1|SysNat |https://github.com/iks-github/SysNat|Operate your software system | |GoogleSearchMassData2|IKS GmbH |https://www.iks-gmbh.com |IKS GmbH: Individuelle Softwareentwicklung und IT-Beratung | |GoogleSearchMassData3|Clean Coding Cosmos|clean-coding-cosmos.de/ |Clean Coding Cosmos | mit Jörg Vollmer und Dr. Reik Oberrath|
-
Start SysNat and check test report.
-
Delete Excel file and create the new file "./sysnat.natural.language.executable.examples/testdata/GoogleSearch/GoogleSearchMassData.dat" with following content:
SearchText=SysNat ExpectedSearchResultText1=https://github.com/iks-github/SysNat ExpectedSearchResultText2=Operate your software system - SearchText=IKS GmbH ExpectedSearchResultText1=https://www.iks-gmbh.com/unternehmen/ ExpectedSearchResultText2=Unternehmen | IKS GmbH - Hilden - SearchText=Clean Coding Cosmos ExpectedSearchResultText1=clean-coding-cosmos.de/ ExpectedSearchResultText2=Clean Coding Cosmos | mit Jörg Vollmer und Dr. Reik Oberrath
-
Start SysNat and check test report for the same results.