LibreOffice has a framework to write C++ unit tests to test accessibility, introduced by Colomban Wendling (Hypra) in the context of a TDF tender. [1] In order to prevent future regressions (and find already existing bugs along the way), it would be great to have more tests, i.e. a larger test coverage. This bug/enhancement report is about writing more tests. Extensive documentation about writing C++ tests with a description of what kind of tests are possible and some ideas where to start is available on this wiki page: https://wiki.documentfoundation.org/Development/Accessibility_Unit_Tests [1] https://blog.documentfoundation.org/blog/2021/10/13/tender-to-implement-c-accessibility-tests-202110-01/
(In reply to Michael Weghorn from comment #0) > Extensive documentation about writing C++ tests with a description of what > kind of tests are possible and some ideas where to start is available on > this wiki page: > https://wiki.documentfoundation.org/Development/Accessibility_Unit_Tests As described in more detail on that wiki page, there are different approaches to improve/extend a11y tests, e.g.: 1) convert existing Java a11y tests to C++ 2) write new tests using the LibreOffice-internal API 3) write new tests to test the platform-specific integration 1) and 2) can be done on all platforms (but tests for 2) that involve dialogs currently don't work on macOS), 3) is currently only implemented for the gtk3 VCL plugin on Linux. (Implementing this for other platforms/VCL plugins is possible, too, but probably more complex than adding more tests. Some more details in Colomban's email: [1]) The wiki page also contains pointers to existing tests/previous commits that give an impression on how to implement tests. [1] https://lists.freedesktop.org/archives/libreoffice/2023-August/090720.html
Michael Weghorn committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/132f22d9f6d58b4e3541ef3e8efe8ef7e3136a23 tdf#157003 a11y: Replace AccessibleDropDownListBox Java with C++ test It will be available in 25.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.