microsoft / axe-windows

Automated accessibility testing engine for Windows applications
MIT License
136 stars 62 forks source link

feat(chrome-scans): Add mechanism for excluding elements from scans #873

Closed sfoslund closed 1 year ago

sfoslund commented 1 year ago

Details

This PR is 2/2 of addressing https://github.com/microsoft/axe-windows/issues/836. https://github.com/microsoft/axe-windows/pull/871 added the ChromiumComponentsShouldUseWebScanner rule and this PR adds logic to exclude elements that fail this rule from further scanning. It also includes logic to ensure that only the top level chrome element reports a ChromiumComponentsShouldUseWebScanner rule violation.

Motivation

Addresses issue #836

Pull request checklist

codecov-commenter commented 1 year ago

Codecov Report

Merging #873 (3759f92) into main (4fc19c3) will increase coverage by 1.21%. The diff coverage is 80.70%.

@@            Coverage Diff             @@
##             main     #873      +/-   ##
==========================================
+ Coverage   73.70%   74.91%   +1.21%     
==========================================
  Files         398      422      +24     
  Lines       12046    13108    +1062     
==========================================
+ Hits         8878     9820     +942     
- Misses       3168     3288     +120     
Impacted Files Coverage Δ
src/Actions/Actions/ControlPatternAction.cs 0.00% <0.00%> (ø)
src/Actions/Actions/CustomUIAAction.cs 0.00% <0.00%> (ø)
src/Actions/Actions/ListenAction.cs 0.00% <0.00%> (ø)
src/Actions/Actions/PrivacyExtensions.cs 100.00% <ø> (ø)
src/Actions/Actions/SetDataAction.cs 0.00% <0.00%> (ø)
...rc/Actions/Attributes/InteractionLevelAttribute.cs 0.00% <0.00%> (ø)
src/Actions/Misc/ExtensionMethods.cs 7.46% <0.00%> (-31.60%) :arrow_down:
src/Actions/Resources/ErrorMessages.Designer.cs 0.00% <ø> (-55.56%) :arrow_down:
src/Automation/AxeWindowsAutomationException.cs 33.33% <ø> (-33.34%) :arrow_down:
src/Automation/Data/OutputFile.cs 88.88% <ø> (ø)
... and 430 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

sfoslund commented 1 year ago

Per windows triage: Closing this for now as we're still undecided as to how best to approach this change. We plan to treat this as a full feature going forward.