Reputation: 11
I have a below scenario: In my script, I am entering the credential and logging to the application, after login it asks for text code that is sent to the mobile device.
Currently, through code only I want to ask user to input the code and navigate to for next actions. Is there any way to do it in squish.
Note: I am automating QT desktop application that is developed in Linux.
I tried input(prompt), but it is not working.
Upvotes: 1
Views: 85
Reputation: 41
You can use testInteraction API (https://doc.qt.io/squish/squish-api.html#testinteraction-functions) provided by Squish.
Example of one of the functions mentioned in the manual:
name = testInteraction.input("Type in your name and press one of buttons below.")
if name == "":
testInteraction.warning("It's sad you don't want to share your name.")
else:
testInteraction.information("Hello %s!" %name)
Upvotes: 1