Skip to content

Commit 8f59b22

Browse files
committed
Bug 1877602 - Update the test case browser/components/customizableui/test/browser_981418-widget-onbeforecreated-handler.js that clicks on an unlabeled toolbarbutton. r=Gijs
The test "[browser/components/customizableui/test/browser_981418-widget-onbeforecreated-handler.js](https://searchfox.org/mozilla-central/rev/2a867dd1ab015c3ef24b774a57709fb3b3dc4961/browser/components/customizableui/test/browser_981418-widget-onbeforecreated-handler.js#35,53)" creates a test widget that has no `label` or `tooltiptext` property that is being clicked. But since its created toolbarbutton has no accessible name, it is being flagged by the a11y-checks. We could add "[tooltiptext](https://searchfox.org/mozilla-central/rev/2a867dd1ab015c3ef24b774a57709fb3b3dc4961/browser/components/customizableui/CustomizableUI.sys.mjs#4249)" property to make this test toolbarbutton accessible without triggering PanelMultiView to be adding header text, etc. Since the issue will be resolved, we should also remove the `fail-if` notation from the test manifest. Differential Revision: https://phabricator.services.mozilla.com/D200115
1 parent 3fff1b9 commit 8f59b22

File tree

3 files changed

+2
-2
lines changed

3 files changed

+2
-2
lines changed

browser/components/customizableui/test/browser.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,6 @@ skip-if = ["verify"]
186186
["browser_981305_separator_insertion.js"]
187187

188188
["browser_981418-widget-onbeforecreated-handler.js"]
189-
fail-if = ["a11y_checks"] # Bug 1854536 clicked chromeclass-toolbar-additional toolbarbutton may not be labeled
190189
skip-if = ["verify"]
191190

192191
["browser_982656_restore_defaults_builtin_widgets.js"]
@@ -244,7 +243,6 @@ skip-if = ["verify"]
244243
["browser_check_tooltips_in_navbar.js"]
245244

246245
["browser_create_button_widget.js"]
247-
fail-if = ["a11y_checks"] # Bug 1854536 clicked chromeclass-toolbar-additional toolbarbutton may not be labeled
248246

249247
["browser_ctrl_click_panel_opening.js"]
250248

browser/components/customizableui/test/browser_981418-widget-onbeforecreated-handler.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ add_task(async function testAddOnBeforeCreatedWidget() {
1313
id: kWidgetId,
1414
type: "view",
1515
viewId: kWidgetId + "idontexistyet",
16+
tooltiptext: "I am an accessible name",
1617
onBeforeCreated(doc) {
1718
let view = doc.createXULElement("panelview");
1819
view.id = kWidgetId + "idontexistyet";

browser/components/customizableui/test/browser_create_button_widget.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ add_task(async function () {
1414
let widgetSpec = {
1515
id: kButton,
1616
type: "button",
17+
tooltiptext: "I am an accessible name",
1718
onClick() {
1819
gBrowser.selectedTab = BrowserTestUtils.addTab(gBrowser, "about:addons");
1920
},

0 commit comments

Comments
 (0)