This question is locked. New answers and comments are not allowed.
Hi,
I tried to record a test with logical If...Else statement but encounter some problem here.
My test steps:
1. navigate to www.random.org
2. set the max value of true random number generator to 2
3. click on the 'Generate' button
4. if (verify the result generated contains 2),
5. then navigate to www.google.com
6. else,
7. navigate to www.yahoo.com
I noticed that my tests will always execute step 6,7 and never go to step 5 even the generated integer is 2. I suspect that WebUI dun even wait for the result generated to be populated, and tht is why step 4 will always be false and will always go to step 6. I tried to use 'Wait for textcontent contains 2' instead of 'verify textcontent contains 2' before i add this verify step into the if statement, but it still give me the same result.
Did i miss out anything here? Any advice?
I tried to record a test with logical If...Else statement but encounter some problem here.
My test steps:
1. navigate to www.random.org
2. set the max value of true random number generator to 2
3. click on the 'Generate' button
4. if (verify the result generated contains 2),
5. then navigate to www.google.com
6. else,
7. navigate to www.yahoo.com
I noticed that my tests will always execute step 6,7 and never go to step 5 even the generated integer is 2. I suspect that WebUI dun even wait for the result generated to be populated, and tht is why step 4 will always be false and will always go to step 6. I tried to use 'Wait for textcontent contains 2' instead of 'verify textcontent contains 2' before i add this verify step into the if statement, but it still give me the same result.
Did i miss out anything here? Any advice?