hartmantis/mac-app-store-chef

Add an update_all action to the mac_app_store resource

Closed this issue · 3 comments

Go to updates tab, click the 'UPDATE ALL' button.

wait_for(:button, ancestor: app_store.main_window.web_area, title: 'UPDATE ALL')

Firmware updates will pop up a warning window and continue button.

app_store.dialog.sheet.button(title: 'Continue')

Note that the popup leads to the web_area becoming inaccessible.

app_store.main_window.web_area

RuntimeError: accessibility messaging failure. Perhaps the application is busy or unresponsive?

And then, of course, updates that result in reboots become an issue. :\

Maybe, it could only run when no updates require a reboot? Or click the Update buttons individually?

Difficulty: The app descriptions and associated 'UPDATE' buttons don't share any parent container. There are no grouped row elements like there are on the Purchases page. They're all their own children under the page's web_area.

Other potentially important pieces:

The Updates page itself:

as.main_window.web_area.description
"Updates"

Button present if there are updates available that require a newer OS X:

as.main_window.web_area.button(title: 'Show Incompatible App Updates'

Upgrade button at the top of the Updates page when a new OS X is available:

as.main_window.web_area.children[3].children[0].button(description: 'Free Upgrade')

The 'Restart Required' label underneath an app update:

as.main_window.web_area.static_text(value: 'Restart Required')

The 'UPDATE' button next to an individual app:

as.main_window.web_area.button(description: 'Install all available Software Updates')

Done by #31