Summary: | mac-wk2 test runner returns null for accessibilityController.accessibleElementById | ||
---|---|---|---|
Product: | WebKit | Reporter: | James Craig <jcraig> |
Component: | Accessibility | Assignee: | Nobody <webkit-unassigned> |
Status: | CLOSED WORKSFORME | ||
Severity: | Normal | CC: | cfleizach, jcraig |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
Description
James Craig
2013-02-06 01:31:18 PST
I think your problem is that PASS: div[role=rowgroup] 923 AXRole: 924 has no role, and in WK2, it returns a null object instead of an empty string Not quite. The axElement actually returns null, not just the properties on the object. Nevertheless, I can work around it like this to normalize the behavior between wk1 and wk2. if (axElement) { role = axElement.role; subrole = axElement.subrole; roleDescription = axElement.roleDescription; } else { role = 'AXRole: '; subrole = 'AXSubrole: '; roleDescription = 'AXRoleDescription: '; } If you think that's expected behavior, it's okay to close this bug. (In reply to comment #2) > Not quite. The axElement actually returns null, not just the properties on the object. Nevertheless, I can work around it like this to normalize the behavior between wk1 and wk2. > > if (axElement) { > role = axElement.role; > subrole = axElement.subrole; > roleDescription = axElement.roleDescription; > } else { > role = 'AXRole: '; > subrole = 'AXSubrole: '; > roleDescription = 'AXRoleDescription: '; > } > > If you think that's expected behavior, it's okay to close this bug. Ah yes, because this is not an AX element in the hierarchy. In WK1, you'll get an empty ax element, on WK2 you'll get a null element. We could leave this out of the test or do a check like if (axElement && axElement.role) Closing |