A Generci Question

Best practices, code snippets for common functionality, examples, and guidelines.
gary
Posts: 17
Joined: Thu Sep 22, 2016 2:52 pm

A Generci Question

Post by gary » Thu Dec 08, 2016 12:50 pm

Hi all

A question for all the gurus out there...... I am trying to automate a basic test (record and play) wherein the system generates a letter for the client. All I want Ranorex to do is verify that the name and address of the customer on the letter is correct. Any suggestions how would I go about automating this ? Thanks in advance.

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 7470
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: A Generci Question

Post by odklizec » Thu Dec 08, 2016 12:59 pm

Hi,

I would suggest you to start with "Data-Driven Test Automation with Ranorex" screencast, available here:
http://www.ranorex.com/support/screencasts.html
This should give you an idea how to properly automate such validation task. Basically, after you record basic steps, you need to convert them to data-driven steps with variables connected to a data source, in which you specify expected reference values, which should be then validated with real values in tested app. Hope this helps?
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

gary
Posts: 17
Joined: Thu Sep 22, 2016 2:52 pm

Re: A Generci Question

Post by gary » Thu Dec 08, 2016 1:10 pm

odklizec wrote:Hi,

I would suggest you to start with "Data-Driven Test Automation with Ranorex" screencast, available here:
http://www.ranorex.com/support/screencasts.html
This should give you an idea how to properly automate such validation task. Basically, after you record basic steps, you need to convert them to data-driven steps with variables connected to a data source, in which you specify expected reference values, which should be then validated with real values in tested app. Hope this helps?
Hi odklizec

My limited understanding is that the Data-Driven Test can be used for where it might be necessary to run the same test with different input data. But in my scenario I am trying to verify if the output data is correct or not. For eg; the letter which is generated (in pdf or html format in my case) have correct client details OR for that matter a row 57 & column M in spreadsheet has 'X' value in it. Is there a screencast available for this sort of test ?

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 7470
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: A Generci Question

Post by odklizec » Thu Dec 08, 2016 1:24 pm

No, I don't think there is such specific screencast available. The data driven approach is of course best to use for repetitive tests with variable input data. However, it's good to use also in case of single data input! You see, it's best to have separated input/reference data from test. Of course, you can completely avoid using data connectors and simply add the validation strings directly to the recording module. But then your module will be static, not reusable and you will have to edit it every time you would like to use it for different email data. Hence it's better to variabilize it and connect it to data source of your choice.

As for your specific problem, as mentioned before, there is not very much I or anyone else here can suggest without seeing an example of PDF/HTML you are working on, or at least a Ranorex snapshot (not screenshot!). I would also suggest you to watch all available screencasts and read through the User Guide, to learn about Ranorex basic and advanced usage techniques. Ranorex is relative easy to learn and use, but there is no way to skip the basic steps ;)
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration