Open Bug 1212026 Opened 9 years ago Updated 2 years ago

Add platform-specific accessibility tests

Categories

(Core :: Disability Access APIs, task)

task

Tracking

()

Tracking Status
firefox44 --- affected

People

(Reporter: fredw, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 file, 1 obsolete file)

Currently, the mochitests in the accessible/ directory only test our internal API via the nsIAccessible interface as well as how that one is used by AccessFu (jsat).

Ideally, we should also have tests for our ATK, MSAA, IAccessible2 and Mac interfaces. We could use ctypes to read the accessibility tree via the appropriate system libraries and write mochitests (incidentally this could also be used for dev tools), although I'm not sure there is a public one for Mac.
Attached patch Patch V1 (obsolete) — Splinter Review
Proof-of-concept patch to test our ATK API using the AT-SPI library. For now, this just adds a basic test to check roles for app, document and paragraph.

https://treeherder.mozilla.org/#/jobs?repo=try&revision=8b1b5cbd511f
Summary: Add platform-specific tests → Add platform-specific accessibility tests
Attached patch Patch V2Splinter Review
I started to write a ctypes API for MSAA, but realized that IAccessible and IAccessible2 are C++ classes... So we can not directly use them with ctypes, we would need to create an intermediate C layer...
Attachment #8670420 - Attachment is obsolete: true
(In reply to Frédéric Wang (:fredw) from comment #1)
 
> Proof-of-concept patch to test our ATK API using the AT-SPI library. For
> now, this just adds a basic test to check roles for app, document and
> paragraph.
> 
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=8b1b5cbd511f

it's yellow btw
(In reply to alexander :surkov from comment #3)
> it's yellow btw

Yes, that's because the try server machines do not have all the system libraries needed by the tests:

> this.glib = ctypes.open("libglib-2.0.so");
> this.gobject = ctypes.open("libgobject-2.0.so");
> this.atspi = ctypes.open("libatspi.so");

It worked for me when I tested locally.
Assignee: nobody → npang

The bug assignee didn't login in Bugzilla in the last 7 months.
:Jamie, could you have a look please?
For more information, please visit auto_nag documentation.

Assignee: npang → nobody
Flags: needinfo?(jteh)

I wasn't aware ctypes was available from mochitests. That opens up some interesting possibilities.

On Windows, we'd need to be able to do stuff with COM. That isn't really supported by ctypes, but this article suggests it is possible, albeit ugly.

Severity: normal → --
Type: defect → task
Flags: needinfo?(jteh)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: