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

Verifying continually changing data between multiple pages

4 Answers 58 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
eugene
Top achievements
Rank 1
eugene asked on 02 Aug 2012, 04:17 PM
Hi,

I tried searching through the help documentation and I may have found what I am looking for, but I'm not too sure.

I want to verify data between multiple pages where the data continually changes, i.e. on a daily, weekly, monthly basis.

My steps would be as follows:
1. Open said page
2. Verify said number
3. Click said number to progress to next page
4. On next page verify said number matches the previous page

Now, these number will constantly be changing (but should always match) so I want to create a test where it will pass if the numbers match, and fail if the numbers don't, and I wouldn't have to manually update the test every time the numbers change.

The test I created was;
1. Open said page
2. Extract 'TextContent' on 'x526Link' into DataBindVariable $(x526Link)  
3. IF (Verify 'TextContent' 'Contains' '526' on 'x526Link') THEN
  • 4. Click 'x526Link'
5. Extract 'TextContent' on 'WeFound526PTag' into DataBindVariable $(WeFound526PTag)
6. Verify 'TextContent' 'Contains' 'We found 526 brands  that ran on all the pages between 1/1/2007 and 5/31/2012.' on 'WeFound526PTag'
7. ELSE


If anyone could lead me in the right direction/provide me with the necessary steps that would be great.


Thanks

4 Answers, 1 is accepted

Sort by
0
Byron
Telerik team
answered on 02 Aug 2012, 05:12 PM
Hi Eugene,

You are definitely on the right track with your test setup. By storing the number on the first page into an extracted variable, you are halfway there. The next step is to data bind the later verification to the contents of the extracted variable. In the test step properties window for step 6, you can select the Text  property under the Data Driven bindings and input the variable name $(x526Link). This will cause the verification to check the target element against the content of the extracted variable.

Kind regards,
Byron
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
eugene
Top achievements
Rank 1
answered on 07 Aug 2012, 02:33 PM
Thanks for your insight Byron. I have changed my test accordingly and will verify it the next time data changes to see if my steps properly work.
0
eugene
Top achievements
Rank 1
answered on 08 Aug 2012, 01:42 PM
Hi Byron,

So it doesn't look like my test worked. I think I have having trouble with the settings for extracting and verifying.
Could you give me a step breakdown of what my steps should look like?

Here are my steps again that I want to perform:
1. Open said page
2. Verify said number
3. Click said number, then progress to next page
4. On next page verify said number matches the previous page

Note: Tomorrow the data may change so I want to re-play this test and verify data correctly matches in steps 2 and 4 even though the numbers may be different.


Thanks
0
Byron
Telerik team
answered on 13 Aug 2012, 03:19 PM
Hi Eugene,

Please find attached a screenshot of the steps to databind a verification. This scenario is based on the random word scenario in the article on creating an extraction step. In addition to extracting a random word and entering that word into Google, I have taken the additional step of creating a verification of the contents of the Google text form and data driving that verification. Data driving a verification is done similarly to data driving an extraction: highlight the step, select the (Bindings) property from the Properties window, and select the extracted variable you wish to bind to the verification.

Please let us know if we can assist you further.

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