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

How to use data driven values in Conditions

1 Answer 40 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Abhishek
Top achievements
Rank 1
Abhishek asked on 05 Feb 2020, 10:56 AM
I want to use data driven values in 'If' statement, something like IF(Data["isDuplicate"].Equals(true)) then execute some steps.

1 Answer, 1 is accepted

Sort by
0
Plamen Mitrev
Telerik team
answered on 06 Feb 2020, 10:07 AM

Hello Abhishek,

The conditional "if" step that you mentioned is a more complex scenario and can be achieved in a coded step. I will be happy to share more details about the steps below.

  • You need to add a coded step to your test, where you want to have the condition.
  • Create your own "if" condition and compare the data as necessary. You can use the following code to get the data from a certain column by the column's name (see point 22 in this article).
    Data["columnName"].ToString();

I hope the above details will help you automate the test scenario. Please do not hesitate to contact us again, if you need further assistance.

Regards,
Plamen Mitrev
Progress Telerik

 
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
 
Tags
General Discussions
Asked by
Abhishek
Top achievements
Rank 1
Answers by
Plamen Mitrev
Telerik team
Share this question
or