This is a migrated thread and some comments may be shown as answers.
Multiple datasource(multiple tables) in a single aii file
3 Answers 27 Views
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Muhammad Zaheeruddin
Top achievements
Rank 1
Muhammad Zaheeruddin asked on 03 Nov 2009, 07:50 PM

 

Hi,

I am creating a data driven test. I have 2 pages: Login.aspx & Calculation.aspx

Login page will take the UserID & Pwd from database tables and after successful authentication it will redirect to Calculation.aspx. Now Calculation.aspx have 4 textboxes whose values suppose to fill from database datasource.

 

In database I have 2 tables, one(lets say Users) for User IDs/Pwd(lets suppose 3 rows) and the other one(lets say MyInput) is for the input values(lets 5 rows) for Calculation.aspx.

 

My requirement is that Test Studio suppose to loop through all the 3 user id(of Users table) and for each iteration it suppose to run 5 iterations(of MyInput table) on Calculations.aspx, which means it should take first userid/pwd from Users table and complete 5 iterations for all 5 values of MyInput table then take 2nd pair of userid/pwd values from Users table, complete same 5 iterations for all 5 values of MyInput table and so on.

 

My question is how can I incorporate 2 tables in a single aii file with multiple outer/inner or sub-iterations?

Looking forward.

Thanks,
Zaheer

3 Answers, 1 is accepted

Sort by
0
Missing User
answered on 03 Nov 2009, 09:31 PM
Hello Muhammad,

WebUI uses Visual Studio's Data Driven Unit Test Implementation, described here.

The datasource only uses one table per test run. You can try binding the steps to the 1st table, converting the steps to code, doing some test count logic , then branch and do a SQL connection call into your next table. For your 2nd table iteration runs, you would have to have blank entries in your 1st table to have the test run the iterations for your 2nd table's data.

You might also be able to use a Configuration File desrcibed here, but it would also take custom code you would need to write, which you can base on the data binding code generated from WebUI.

Kind regards,
Nelson Sin
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Syed Danish
Top achievements
Rank 1
answered on 04 Nov 2009, 04:33 PM
Hi Nelson,
I am working with Zaheer. First of all thank you for your reply however there are still few questions remaining.

1. As this product will be used by the Business Analysts/QA folks to create the test cases/scenarios who obviously don't have an in depth coding experience to write customized code using a .Net language and for obvious reasons they don't need to be expert in coding/programming so Is there any way this product can help them achieving what they are trying to?

2. Let me further elaborate our our test case scenario which is pretty simple. We need to simulate customer service aganets Login experience and submission of their customers information. So the automated test case should simulate a CSA login using login credentials information from database and allows him to submit multiple customers information so first iteration would be to login the CSA and second iteration would be to submit customer information multiple times for the same CSA. It would not be logical to login the CSA, submit customer information and then display login screen again and relogin the same CSA to submit second customer information and so on.

3. Lastly, even if there is no other solution and we have to create custom code for opening connections to database and write custom logic for looping around the steps, can you please provide some proper detailed documentation on how to do it? We need some Telerik API reference about writing custom test code and how to branch/jump from one test step to other to achieve the iterative behavior.

Thanks,

Syed Danish.
0
Missing User
answered on 04 Nov 2009, 06:08 PM
Hi Syed,

From the scenario you described, WebUI would not support this out of the box. You have the option to write code to extend the data driven feature to get the scenario working, but we currently do not have any code models as we use the Visual Studio data driven implementation.

But based on what WebUI can do for you, it might be easier to created a testing table in your database that would contain the information you would need to test the scenario succesfully.

All the best,
Nelson
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
General Discussions
Asked by
Muhammad Zaheeruddin
Top achievements
Rank 1
Answers by
Missing User
Syed Danish
Top achievements
Rank 1
Share this question
or