Reputation: 8727
We have a Windows 7 GUI tool just like MS Paint and need to test this application using Robot Framework.
Is there a possible way that we can select / execute different menu options by of the GUI tool - I have no code to share as I am not sure even how to implement it
Upvotes: 1
Views: 2447
Reputation: 2881
You could use robotframework-autoitlibrary
it allows us to automate desktop application.
AutoItLibrary is a Robot Framework keyword library wrapper for for the freeware AutoIt tool, using AutoIt's AutoItX.dll COM object. The AutoItLibrary class provides a proxy for the AutoIt keywords callable on the AutoIt COM object and provides additional high-level keywords implemented as methods in this class.
This link contains all the information you need about keywords, how it works etc.
You could also write keywords in python and then use them in robot-framework for that you could use pywinauto
library
Example code:
from pywinauto.application import Application
def Open_And_Click:
app = Application()
app.start_("C:\\Temp\\setup.exe")
mainWindow = app.SampleApplication
mainWindow.Wait('ready')
mainWindow['&Next'].ClickInput()
mainWindow['&Next'].ClickInput()
mainWindow['&Finish'].ClickInput()
mainWindow.WaitNot('visible')
Upvotes: 3