LDTP  3.5.0
 All Pages
getallstates

Syntax

getallstates('<window name>'[, '<component name>'])

Description

Will return all the accessibility states of given object information

Return values
listof states will be returned on success, LdtpExecutionError exception on failure

Refer: Linux: http://cgit.freedesktop.org/ldtp/ldtp2/tree/ldtpd/core.py

Mac: https://github.com/ldtp/pyatom/blob/master/atomac/ldtpd/core.py

Windows: https://github.com/ldtp/cobra/blob/master/Ldtpd/Generic.cs

Example

from ldtp import *

getallstates() # Will return all the accessibility states of given object information Compare all the states based on your requirement, say for example, if interested in checking for VISIBLE state, then:

states = getallstates('*-gedit', 'btnCopy') if state.VISIBLE in states: print 'Object is visible'

Author
Nagappan Alagappan nagap.nosp@m.pan@.nosp@m.gmail.nosp@m..com


Linux Desktop Testing Project