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

Multi level data driven tests

5 Answers 86 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Tim
Top achievements
Rank 1
Tim asked on 07 Mar 2012, 02:22 PM

Hey
I have a problem trying to get one test to use data from the test that calls it.

I think my problem is exactly descriped at
http://www.telerik.com/automated-testing-tools/support/documentation/user-guide/data-driven-testing/multi-level-tests.aspx , under the header: "Data bound Test A calls Test B".

Unfortunately I can’t seem to get Test B to use data from a source attached to Test A. If I don’t attach the data file to Test B but have it attached to test A, the test automatically fails. If I do attach the data file to Test B and have it attached to test A, the test does not automatically fail, but it will run test B ones for each row of Data in the data file before continuing with test A.

The behavior I’m trying to get is that Test A runs multiple times (ones for each row in the data set) and test B uses the data appropriate for that iteration from the same data set.

Any help would be welcome.

5 Answers, 1 is accepted

Sort by
0
Accepted
Plamen
Telerik team
answered on 07 Mar 2012, 03:41 PM
Hello Tim,

All you need to do is to check the "InheritParentDataSource" property on the Test B. This will cause the subtest to consume/use all the data offered by the parent test(Test A), effectively passing that data in as a parameter for the subtest to use.

All the best,
Plamen
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Patricia
Top achievements
Rank 1
answered on 24 Aug 2012, 09:33 PM
I'm having the same issue.   I have the inheritparent data checked, however, when I'm in test B it won't let me enter the binding for the colum in Test A. I just upgraded to 2012.1.719.0  Any thoughts?
0
Plamen
Telerik team
answered on 27 Aug 2012, 10:53 AM
Hi Patricia,

The column names are not displayed in the Binding properties of the subtest. When you are binding a step from a subtest to its parent data source, you have to enter the column name manually. Please see this video for more information.

Regards,
Plamen
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Zvi
Top achievements
Rank 1
answered on 17 May 2016, 09:53 AM

Hi

I'm facing the same problem.

Since this video is no longer available, could you please explain how to enter the column name of the parent data source manually?

Thanks,

Zvi

0
Elena
Telerik team
answered on 19 May 2016, 01:18 PM
Hello Zvi,

Thank you for contacting Telerik Support Team. 

To manually add the column name expand the Bindings and type the name of the respective column in the field for Add coded data variable then click on the brackets and set it. In the attached screenshot the variable in question is named 'exVal'. 

Please let me know if this information was helpful to you or further assistance will  be required. If so please elaborate more on your particular scenario. Thank you for your understanding and hope to hear from you soon! 

Regards,
Elena Tsvetkova
Telerik
 
The New Release of Telerik Test Studio Is Here! Download, install,
and send us your feedback!
Tags
General Discussions
Asked by
Tim
Top achievements
Rank 1
Answers by
Plamen
Telerik team
Patricia
Top achievements
Rank 1
Zvi
Top achievements
Rank 1
Elena
Telerik team
Share this question
or