TestProject Forum

Automate the "Radio button" selection randomly!

Hello everyone,
I’m testing a website, and one of the pages contains five radio buttons.
Is there any possibility to automate the selection of each radio button randomly? I want to automate this action, so whenever I run the test, a random radio button will be selected automatically.
Cheers!
O

I’m new to testproject but you can get the desired result by using the Generate Random number.


as shown above. You need to get the xpath of the radio button and modify the xpath.
image

result

second run

image

2 Likes

Thank you very much. Its very helpful.
Cheers!
O

1 Like