Forum Discussion

antonyb_1989's avatar
antonyb_1989
New Contributor
13 years ago

Using variables in a property checkpoint

Hey,



Is it possible to use project/projectsuite/keyword test variables in a property checkpoint? 



I have gotten the variables set up to collect their values when the keyword test runs, I then need to check something further in the test against the variable, to make sure that the new checkpoint is equal to the variable. 



I've been racking my brain for ages trying to figure out how to compare the contentText of a DIV in HTML5 to the variable value.



Thanks for your time, input & help appreciated!



-Tony.

3 Replies

  • jose_pita's avatar
    jose_pita
    Super Contributor
    Hi Tanya,



    Is it possible to insert * on a checkpoint in order to make it dynamic/ to ignore some parts of the text?



    For example :




    aqObject.CheckProperty(Aliases.browser.acaoColetiva.panel1.panel.frameIframecontent.panelActo151956.table, "contentText", cmpEqual, "Ação Coletiva\nData da Ação\n"+Project.Variables.dataDeHoje+"*"+"something else", false);




    Thank you.

  • For now I have taken to setting 2 variables from their respective areas and using an If function to compare the 2 of them. Not perfect, but it's a temporary solution until I find an answer.