I have the following use case for a web app:
1) A test suite comprising of 10 test cases
2) TC 1 - Open Browser, TC 2 - login, TC 3 - Search for a product, TC 4 - Add product to card, TC 5 Check out, ... TC 10 Close browser.
I need to able to do the whole cycle (test suite) on 3 different browsers (IE, Firefox, and Chrome). I am able to iterate a single test case only by have three rows of test data. However, this would not help as this would only Open IE first and open Firefox and then open Chrome.
What I would like to do is open IE and run the rest of the test case, close IE and then on the second iteration, open Firefox and run the rest of the test case and do the same on Chrome. This way I would be able to complete my testing on all three browsers without manually having to change the browser type after each iteration.
Thanks for the help!
Looping/Iterating a test suite (not a test case)
Re: Looping/Iterating a test suite (not a test case)
Hi,
The easiest way to achieve what you want is to enclose all 10 TCs in one "master" TC with data connector, containing IE, FF and Chrome iterations. This "master" TC will then loop all your TCs in each specified browser.
So the whole structure of your solution should look like this:
Hope this helps?
The easiest way to achieve what you want is to enclose all 10 TCs in one "master" TC with data connector, containing IE, FF and Chrome iterations. This "master" TC will then loop all your TCs in each specified browser.
So the whole structure of your solution should look like this:
Code: Select all
TC0 (data connector with Browsers here)
|_TC1
|_TC2
...
|_TC10
Pavel Kudrys
Ranorex explorer at Descartes Systems
Please add these details to your questions:
Ranorex explorer at Descartes Systems
Please add these details to your questions:
- Ranorex Snapshot. Learn how to create one >here<
- Ranorex xPath of problematic element(s)
- Ranorex version
- OS version
- HW configuration
Re: Looping/Iterating a test suite (not a test case)
Previous answer is correct. It's not obvious initially but you can have Test Cases inside other test cases.
I would add that it's recommended to join test scripts into the test cases that actually do a real tests for you.
In your example TC 1 is Open browser.
What if this test pass or fail, did you find any bugs in your solution that you are developing? It sounds like you need to have something like this:
Test Suite:
TC 0 "SetParameters"
..script: read Browser, user credentials, etc from datasource
..TC 1 "OpenBrowser_Login_EnsureHomePageLoaded":
.... script 1: Open browser
.... script 2: Login to your webpage
.... script 3:
..TC 2 "Read product details"
and so on
Try to differentiate technical steps from real testing
I would add that it's recommended to join test scripts into the test cases that actually do a real tests for you.
In your example TC 1 is Open browser.
What if this test pass or fail, did you find any bugs in your solution that you are developing? It sounds like you need to have something like this:
Test Suite:
TC 0 "SetParameters"
..script: read Browser, user credentials, etc from datasource
..TC 1 "OpenBrowser_Login_EnsureHomePageLoaded":
.... script 1: Open browser
.... script 2: Login to your webpage
.... script 3:
..TC 2 "Read product details"
and so on
Try to differentiate technical steps from real testing
Re: Looping/Iterating a test suite (not a test case)
With your suggested configuration, I was able to successfully achieve what I was looking for.
I appreciate the help guys. Thanks.
I appreciate the help guys. Thanks.