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

Resuable Login Test

3 Answers 19 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
B
Top achievements
Rank 1
B asked on 08 Nov 2012, 09:07 PM
Hi,

Our team is currently evaluating Test Studio and we were wondering how to go about creating a login test that can accept a user/password and be reused in other scripts?

I've read a few forum posts on this subject and believe the approach is to use the Test as Step / Data Driven approach, however I'm not 100% sure which of our tests I need to modify in Test Studio to achieve this :-) I've attached a picture of the current project structure.

Currently I have a _LOGIN test (with a hardcoded user/password) that is called via Test As Step by both the CreateStringFilter and ViewDashboard tests. I'd like to modify it so CreateStringFilter can use a username & password of admin/admin and ViewDashboard QA/12345.

Is anyone able to outline the steps based on our test structure to set this up?

Cheers,
Brett

3 Answers, 1 is accepted

Sort by
0
Accepted
Plamen
Telerik team
answered on 09 Nov 2012, 09:19 AM
Hello Brett,

In order to achieve this, you need to bind the parent tests to a local or external data source. Then check "InheritParentDataSource" on the login subtest. This will cause the subtest to consume/use all the data offered by the parent test, effectively passing that data in as a parameter for the subtest to use. See the first scenario described in this article for more information.

Regards,
Plamen
the Telerik team
Are you enjoying Test Studio? We’d appreciate your vote in the ATI automation awards.
Vote now
0
B
Top achievements
Rank 1
answered on 12 Nov 2012, 01:10 AM
Great, thanks for that
That helped clarify what I needed to change :-) Got it working now
0
Plamen
Telerik team
answered on 12 Nov 2012, 08:40 AM
Hello Brett,

Glad to hear it! Please contact us again if you have further problems.

Regards,
Plamen
the Telerik team
Are you enjoying Test Studio? We’d appreciate your vote in the ATI automation awards.
Vote now
Tags
General Discussions
Asked by
B
Top achievements
Rank 1
Answers by
Plamen
Telerik team
B
Top achievements
Rank 1
Share this question
or