I'm using QAF Automation framework with Selenium Web Driver, Java, TestNG and been successful in executing one test at a time, remotely on Sauce labs. But my test executes for Windows OS, when I want it to execute on Mac OS. Not sure why windows is being selected by default.
The only properties I provided are:
remote.server=http://username:ACCESS_KEY@ondemand.saucelabs.com:80/wd/hub
remote.port=80
driver.name=chromeRemoteDriver
Where should I mention in QAF Framework?
multiple OS - Windows or Mac OS
different browsers to use - Firefox, Chrome, Safari and IE.
I tried OS/browsers in config.xml file (testng.xml) as parameters but not sure why it's not working.
If you've worked with QAF frameworks before and successful with sauce parallel execution, please help!
driver.name
<driver>.additional.capabilities={'<capabilityname1>'='<value1>','<capabilityname2>'=<value2>}
or
<driver>.capabilities.<capabilityName1>=c1value <driver>.capabilities.<capabilityName2>=c2value
Refer setting driver capabilities for detailed documentation.
You can use Sauce Labs Platform Configurator to correctly configure the required test capabilities for your Appium and Selenium tests. It will generate code fore capabilities to use. For example, on selecting Api -> Selenium, Device -> Mac, Operating system - >Mac OS Sierra, Browser -> Chrome 61.0 it will generate following java code.
When usig QAF you can provide capability using property as below
You can use different combinations as documented in setting driver capabilities.
If you want to run your test on different browser/os combination you can do it in config file. Here is the example configuration file