The Zurich release has arrived! Interested in new features and functionalities? Click here for more

ATF: Validate List Values and Look up field values

pratap_chiluver
Tera Contributor

Hello Everyone,

Have below two questions, wanted to know the possibility with script or UI Step.

1) I am looking for a way to validate the the Reference field values are coming correctly or not.

        For Ex: In Incident Table I wanted to validate the values of the field "Caller" (This is an example. In real time scenario, the developer will apply a filter criteria before populating the values to this reference field and tester is responsible to validate the number of records and the values too).

find_real_file.png

2) Do we have a way to validate the drop down field values (the values could be hard-coded or coming from a table). In this example wanted to validate the "State" field values, with script or a UI Step.

find_real_file.png

10 REPLIES 10

Here's an example of testing a script include which I assume you are using on some of your reference fields:



Automated Test Framework use case: test a script include



I tried on my side, but ran into a obstacle when trying to call a function that is within the script include. Looking at the example more I'll try again and let you know if I make any progress.



For a choice list you can probably have several steps that update the record state to the various options and then you validate the field value after each time you update it.


pratap_chiluver
Tera Contributor

We only can run server side script, but I obviously want to validate the values from the client side right? I probably can validate the values from the Reference table, but I never be sure about them loading in the UI correctly or not


pratap_chiluver
Tera Contributor

May be there is no way to do it??




Testing advanced reference qualifier using ATF


prasiyalraj
Giga Expert

Hi Pratap,



Please enable the JavaScript Log and Field Watcher in the Setting > Developer > JavaScript Log and Field Watcher.



Which makes you to know the client script script running or not against the form..



I am not sure whether I am answering your question.



Thanks


Prasiyal


Gorkshanath Man
Tera Contributor

Hi Pratap,

 

For validating drop down values, If you have admin rights. Go to Choice Lists under system definition.

Then on that list apply filter with your table name and element(dropdown Field). You will get all the records that are present in that dropdown. Then apply filter on label(your dropdown values) as well and check record is present. It will not work every time specially if there is any rule for values to be visible, but you can try.