Commit 9935d5ae authored by Jack Lynch's avatar Jack Lynch Committed by Commit Bot

DevTools: Add accessibility test for threads pane

This CL adds an axe accessibility test for the threads pane.

Bug: 963183
Change-Id: I35dc2738f7bd5fce2e4b24aaa6a86b51b671b982
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1707832Reviewed-by: default avatarRobert Paveza <Rob.Paveza@microsoft.com>
Commit-Queue: Jack Lynch <jalyn@microsoft.com>
Cr-Commit-Position: refs/heads/master@{#729933}
parent 3df4d9f6
Testing accessibility in the threads sidebar pane.
Threads sidebar pane content:
Mainworker-source.jspaused
Running the axe-core linter on the threads sidebar pane.
aXe violations: []
// Copyright 2019 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
(async function() {
TestRunner.addResult('Testing accessibility in the threads sidebar pane.');
await TestRunner.loadModule('axe_core_test_runner');
await TestRunner.loadModule('sources_test_runner');
await TestRunner.showPanel('sources');
await SourcesTestRunner.startDebuggerTestPromise(/* quiet */ true);
await TestRunner.evaluateInPagePromise(`new Worker('../../sources/resources/worker-source.js')`);
await SourcesTestRunner.waitUntilPausedPromise();
const sourcesPanel = UI.panels.sources;
sourcesPanel._showThreadsIfNeeded();
const threadsSidebarPane = await sourcesPanel._threadsSidebarPane.widget();
const threadsSidebarElement = threadsSidebarPane.contentElement;
TestRunner.addResult(`Threads sidebar pane content:\n ${threadsSidebarElement.deepTextContent()}`);
TestRunner.addResult('Running the axe-core linter on the threads sidebar pane.');
await AxeCoreTestRunner.runValidation(threadsSidebarElement);
TestRunner.completeTest();
})();
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment