Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Acknowledge alers on Perfherder UI
function getPageNumber() {
const previous = document.querySelector("[aria-label='Previous']");
return previous.closest("[aria-label*='Page']").getAttribute("aria-label").replace("Page ", "") * 1;
}
(async () => {
while (getPageNumber() > 1) {
document.querySelectorAll("[data-testid*='summary'].form-check-input").forEach(e => e.click())
await new Promise(r => setTimeout(r, 3000));
document.querySelectorAll('.btn-secondary [data-icon="check"]').forEach(e => e.parentNode.click())
await new Promise(r => setTimeout(r, 3000));
document.querySelector("[aria-label='Previous']").click();
await new Promise(r => setTimeout(r, 3000));
}
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment