This is a migrated thread and some comments may be shown as answers.

Data-Driven Test for Log-on verification

3 Answers 92 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Mariko
Top achievements
Rank 1
Mariko asked on 13 Jul 2011, 02:40 AM
Hi,

I've created this post to avoid confusion with my other post.

We have this test for Log on verification.
Scenario 1 for the normal process(Valid Users) and Scenario 2 for the negative test(Invalid Users).
We've put those scenarios in a datasource to be able to leverage the data-driven capability of the test studio.
After running the test, we noticed that Scenario 2 behaves like Scenario 1. Which is not the expected.
We later on observed that Test Studio doesn't closes the browser on every end of each iteration. So credentials for Iteration2 is actually the credentials for iteration1.  
We tried adding a 'Clear Cached' step but it still behaves the same.
We also tried to set the Behavior Property ClosesBrowser = True but still the same.
We also tried your suggestion on my other post to put the 'Clear Cached' step on the 1st step but still no luck.
And unfortunately, the design of our application page doesn't have a Log-off button.

Any thoughts on this?

Thanks,
Mariko

3 Answers, 1 is accepted

Sort by
0
Accepted
Anthony
Telerik team
answered on 13 Jul 2011, 04:30 PM
Hi Mariko,

The "Clear Cookies" step is not successful because it is likely targeting persistent cookies and not browser session cookies. Since the browser does not close between iterations of a data driven test, those persistent cookies remain.

To close and reopen the browser between iterations, insert a script step at the end of your test. Its code will be as follows:

//Close the active browser window
ActiveBrowser.Window.Close();
 
//Launch a new browser instance
Manager.LaunchNewBrowser();

Kind regards,
Anthony
the Telerik team
Register today for a live 'What's New in Test Studio R1 2011 SP2' event on Tuesday, July 19 at 2pm EST!

Have you looked at the new Online User Guide for Telerik Test Studio?
0
Mariko
Top achievements
Rank 1
answered on 14 Jul 2011, 02:40 AM
Thanks again Anthony! :)

Hmm... just for another "nice to have", maybe you could add this close browser step on the "Add" toolbar so that adding of "script steps" are minimized.

Cheers,
Mariko
0
Anthony
Telerik team
answered on 14 Jul 2011, 04:06 PM
Hello Mariko,

Thanks again for the great feedback. I agree this would be a convenient addition and logged it as a Feature Request.

Best wishes,
Anthony
the Telerik team
Register today for a live 'What's New in Test Studio R1 2011 SP2' event on Tuesday, July 19 at 2pm EST!

Have you looked at the new Online User Guide for Telerik Test Studio?
Tags
General Discussions
Asked by
Mariko
Top achievements
Rank 1
Answers by
Anthony
Telerik team
Mariko
Top achievements
Rank 1
Share this question
or