testing/marionette/atoms/HOWTO

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

michael@0 1 These atoms are generated from the selenium trunk. They are minified versions of what's in the trunk,
michael@0 2 optimized to run on Firefox. To generate them, clone the repo:
michael@0 3
michael@0 4 svn checkout http://selenium.googlecode.com/svn/trunk/ selenium-read-only
michael@0 5
michael@0 6 then run the Google closure compiler and specify which atom you'd like to get.
michael@0 7 For example, this will generate the "get_text" atom:
michael@0 8
michael@0 9 cd selenium-read-only
michael@0 10 ./go //javascript/webdriver/atoms:get_text:firefox
michael@0 11
michael@0 12 This generates the atom, which is a function. You'll need to assign that function to a variable of your choice
michael@0 13 which you can then import, i.e.: you'll need to modify the atom with a variable assignment:
michael@0 14
michael@0 15 var myVar = <atom code>
michael@0 16
michael@0 17 You can now import this atom and call it with myVar(). Please note the name of the function as a comment above this line to help readability in the atoms file.
michael@0 18
michael@0 19 For more information on atoms, refer to http://code.google.com/p/selenium/wiki/AutomationAtoms#Atoms_Summary
michael@0 20
michael@0 21 Currently bundled atoms (please update as you add more):
michael@0 22 - clearElement
michael@0 23 - click
michael@0 24 - getAttributeValue
michael@0 25 - getElementText
michael@0 26 - isElementDisplayed
michael@0 27 - isElementEnabled
michael@0 28 - isElementSelected
michael@0 29 - sendKeysToElement/type

mercurial