Automating Desktop Application by using Robot Framework

I am New to Automation testing and trying to automate a desktop application by using Robot framework /Keywords/SeleniumLibrary/Eclipse IDE.
Which libraries i required to include other than SeleniumLibrary or any suggestions which is the best way to automate Desktop application by using Robot framework by using Keywords ?

SeleniumLibrary can be used only for automating applications that runs in a modern browsers and nothing else. If you application is not running on browser, then answer depends in which operating system (Windows, Linux, Mac) your application is using and what kind of technology is used to build your application.

Thank you for your Response
I am using windows Operation System and my application build by using Java Technology.

Well, I have not used Java for long time and therefore do not know is there a Java specific library available (Other than the SwingLibrary) but there are generic windows UI libraries available, like WhiteLibrary.

Thank you very much for your quick response .
Has anyone used AUTOITLIBRARY as part of Automating Windows application ?

In my current job, I have built Windows UI automation on top of the pywinauto. But that is all custom stuff and can not be released as open source.

I use AutoItLibrary to detect the position of windows and ImageHorizonLibrary for image comparison as well as interaction (clicks, typing). I tried to install WhiteLibrary a few weeks ago but it didn’t seem to be usable. Many of my colleagues use the Sikuli library instead of ImageHorizonLibrary but I’ve had better results with the former.

Thanks for your Response , could you please help me on following issue

To Launch the Windows application , i have used following keywords and tried with 2 different libraries

  1. SikuliLibrary

Open Application [Path - i have given application path here]

After running the script , Test result showing passed
But on the desktop , error showing as ‘Unexpected Error has Occurred’. Object Reference not set to an instance of an object.

2)AutoITLibraray

The following is the actual Syntax for the Keyword

Run [Filename , workingDir= , Flag= ]

But i have given as follows

Run [filename - i have given application path and i have not mentioned any Working Dir and Flag]

After running the script , Test result showing passed
But on desktop error showing as ‘Unexpected Error has Occured’. Object Reference not set to an instance of an object.

I actually just use the stock process library to start and close the process. Example:

Run Process  ${ExeName} ${Arguments}
...  shell=True
...  timeout=${Timeout} 
...  on_timeout=terminate
...  cwd=${AppRoot}

but there are generic windows UI libraries available, like WhiteLibrary.

Afaik, there is nobody maintaining WhiteLibrary anymore and then there is this pull request: Add deprecation notice by tfrisk · Pull Request #174 · Omenia/robotframework-whitelibrary · GitHub

TestStack.White has deprecated and that means our maintenance will also stop.

Does anyone automated Windows Application with the combination of Winium/Robot Framework / Keywords ?

Hello all
I am the author and maintainer of FlaUI (and previous maintainer of White) and I just got notified about someone who started a FlaUI wrapper for robot framework. See https://github.com/GDATASoftwareAG/robotframework-flaui
Give it a go and return feedback if you have any.
Regards
Roman

4 Likes

Hi All,

I am started working on desktop automation using robotframework\RIDE\White Library.

I was stuck on reading row value from grid for a week.

please let me know can we do the automation for .net winforms grid using white library … please suggest your inputs or help to get out of the issue

Hi there, not sure if this comes late or not. I have been battling this situation for the past month but I seemed to make this work finally:
Robot Framework + Zoomba Library + WinAppDriver! That’s all you need!

2 Likes

Do you only use an US keyboard layout in your tests and your development machine? As far as I know, WinAppDriver has this strange limitation that ‘send keys’ only works properly with an us qwerty keyboard (i.e. it might send a ‘z’ instead of a ‘y’)
Or do you have a good workaround?
I would really like to use zoomba and WinAppDriver, but this limitation seems like a blocker for me.

Hi Many, when I am not able to get it right I just go straight on to Pyautogui lib. If you feel comfortable with python, this is the way to go. Yes, another dependency for your project, but I find this library very useful overall. You’d need to write a wrapper to set your customized keywords for integration with Robot Framework.

Library documentation:
https://pyautogui.readthedocs.io/en/latest/quickstart.html#keyboard-functions

Presentation of the project (min 10:54):

1 Like

Thanks a lot for the idea !
So it means, instead of using the zoomba keywords
‘input text’ or ‘wait for and input text’ (which I believe both use ‘send keys’ from WinAppDriver) I only click into the text fields with Zoomba library and afterwards input the text via pywinauto?
Might be a possible workaround.

2 Likes

Ok, just did my first experiments with flaui.

So far, I’m pretty happy with it

Hi Many, did not know about this library, thanks for sharing.
Regarding Pyautogui, that is absolutely it!

I am glad the workaround worked out. :slight_smile:

1 Like

Hello.

We were trying the library to get things done. We have a third-party desktop application and we were trying to enter some values once the application is opened. Tried many times and its not working.