4723
. All that's left is to decide what to automate!platformName
should be set to Windows
platformVersion
should be set to 10
deviceName
should be set to WindowsPC
app
should be set to the App ID of the app you want to test. For an app that you've created, the WinAppDriver docs state:You can find the Application Id of your application in the generatedAppXvs.appxrecipe
file underRegisteredUserModeAppID
node. E.g.c24c8163-548e-4b84-a466-530178fc0580_scyf5npe3hv32!App
Microsoft.BingWeather_8wekyb3d8bbwe!App
.driver.getPageSource()
to have a look at the source XML. I found it to be quite useful, with plenty of sections like this, that clued me into the most helpful available attributes:ListItem
element which shows a particular day of the week along with a little weather summary. We can see that the Name
attribute has most of the information I might want, including the date, the high and low temperatures, and a weather forecast. I could easily find this element via the name
locator strategy, or (as I ended up doing), using xpath
.AutomationId
attribute set, and for these elements, we can use the corresponding attribute as the selector for the accessibility id
locator strategy.