2

I want to test a Desktop application (proprietary software), using WinAppDriver whereas the test is written in Robot Framework and /or Appium if Appium is needed at all.

I need one example test case using Robot Framework which will use WinAppDriver (WADLibrary) and/or Appium, exercising the opening of an application, clicking a button in a dialog and closing the application.

Any help will be appreciated.

So far I have done it this way, practically using AutoItLibrary as I could not figure out to how to do it using WinAppDriver:


Code Picture

It opens the software but does not click on the button. Any help will be greatly appreciated. Even links where I can find and understand how I can make a Robot Framework test exercising winappdriver to test a desktop application. I have been searching robot framework using WinAppDriver examples but not much success. Thank you

  • 1
    Do not use screenshots to provide code examples, this makes it impossible for people to reproduce your problem. In addition you're providing a working example for AutoIT but not your attempt for WADLibrary. Please provide your WADLibrary example and any observations/errors you may see. Have you had a look at the WADLibrary [Demo Robot Script](https://github.com/Adwisit/WADLibrary/blob/master/Demo/wadlibrary_demo.robot)? – A. Kootstra Feb 17 '20 at 11:34
  • Is it really necessary to use AutoItLibrary and WADLibrary in parallel? – Christoph Jüngling Feb 28 '20 at 12:41

1 Answers1

0

If you are open to a different library perhaps you could try robotframework-zoomba?

Here are the example test in robot.

Essentially it would look like:

*** Settings ***
Library    Zoomba.DesktopLibrary
Library    Common.py
Library    Operating System

*** Variables ***
${REMOTE_URL}         http://localhost:4723/wd/hub
${someSoftware}       Path/To/Software.exe

*** Test Cases ***
Result_Viewer
    Open Application        ${REMOTE_URL}     platformName=Windows    deviceName=Windows   app=${someSoftware}
    Wait For And Click Element     xpath/id/etc
    Close Application

Keyword documentation can be found here

  • I guess, to open the Windows desktop application, we need to run the Appium server. We need to install Appium using npm install and then run. That would be additional steps we need to follow. Also, Appium server should be running. – user392688 Jul 15 '21 at 18:27
  • @user392688 It can also be done with WinAppDriver directly in this example without the use of Appium. https://github.com/Accruent/robotframework-zoomba/blob/master/samples/WinAppDriver-DesktopTests.robot – Brandon Wolfe Jul 21 '21 at 20:11