Home | History | Annotate | only in /external/chromium_org/chrome/test/chromedriver
Up to higher level directory
NameDateSize
alert_commands.cc10-Mar-20153K
alert_commands.h16-Dec-20141.7K
archive.py10-Mar-20152.9K
basic_types.cc16-Dec-20141,008
basic_types.h16-Dec-2014822
capabilities.cc10-Mar-201520.4K
capabilities.h10-Mar-20154K
capabilities_unittest.cc10-Mar-201520.2K
chrome/10-Mar-2015
chrome_launcher.cc10-Mar-201530.4K
chrome_launcher.h16-Dec-20141.6K
chrome_launcher_unittest.cc10-Mar-20157.8K
chrome_paths.py16-Dec-20141.2K
client/10-Mar-2015
command.h16-Dec-2014714
command_listener.h10-Mar-2015711
command_listener_proxy.cc10-Mar-2015729
command_listener_proxy.h10-Mar-2015928
command_listener_proxy_unittest.cc10-Mar-20151.1K
commands.cc10-Mar-20159.3K
commands.h16-Dec-20141.9K
commands_unittest.cc10-Mar-201521.8K
cpp_source.py16-Dec-20142.2K
DEPS16-Dec-2014275
element_commands.cc10-Mar-201516.5K
element_commands.h16-Dec-20145.7K
element_util.cc10-Mar-201520.7K
element_util.h16-Dec-20143.8K
embed_extension_in_cpp.py16-Dec-20141.1K
embed_js_in_cpp.py16-Dec-20141.5K
embed_mobile_devices_in_cpp.py10-Mar-20151.4K
embed_user_data_dir_in_cpp.py16-Dec-2014981
embed_version_in_cpp.py16-Dec-20141.1K
extension/16-Dec-2014
js/10-Mar-2015
key_converter.cc16-Dec-201411.8K
key_converter.h16-Dec-20141.4K
key_converter_unittest.cc16-Dec-201415.9K
keycode_text_conversion.h16-Dec-20141.5K
keycode_text_conversion_mac.mm16-Dec-20143.7K
keycode_text_conversion_ozone.cc16-Dec-2014923
keycode_text_conversion_unittest.cc16-Dec-20145.7K
keycode_text_conversion_win.cc16-Dec-20142.1K
keycode_text_conversion_x.cc16-Dec-20147.6K
logging.cc10-Mar-20159.4K
logging.h10-Mar-20152.8K
logging_unittest.cc10-Mar-20155.6K
net/10-Mar-2015
OWNERS10-Mar-201581
performance_logger.cc10-Mar-201510.4K
performance_logger.h10-Mar-20153.7K
performance_logger_unittest.cc10-Mar-201512.8K
README.txt16-Dec-20144K
run_buildbot_steps.py10-Mar-201518.8K
server/10-Mar-2015
session.cc10-Mar-20153.4K
session.h10-Mar-20152.9K
session_commands.cc10-Mar-201521.2K
session_commands.h16-Dec-20144.9K
session_commands_unittest.cc10-Mar-20154.9K
session_thread_map.h16-Dec-2014517
session_unittest.cc10-Mar-20153.1K
test/10-Mar-2015
test_util.cc16-Dec-20142K
test_util.h16-Dec-20141.6K
third_party/16-Dec-2014
util.cc10-Mar-201514K
util.h10-Mar-20151.7K
util.py16-Dec-20144.8K
util_unittest.cc10-Mar-20151.9K
VERSION16-Dec-20145
window_commands.cc16-Dec-201427.1K
window_commands.h16-Dec-20148.2K

README.txt

      1 This file contains high-level info about how ChromeDriver works and how to
      2 contribute.
      3 
      4 ChromeDriver is an implementation of the WebDriver standard,
      5 which allows users to automate testing of their website across browsers.
      6 
      7 See the user site at https://sites.google.com/a/chromium.org/chromedriver/
      8 
      9 =====Getting started=====
     10 Build ChromeDriver by building the 'chromedriver' target. This will
     11 create an executable binary in the build folder named
     12 'chromedriver[.exe]'.
     13 
     14 Once built, ChromeDriver can be used interactively with python.
     15 
     16 $ export PYTHONPATH=<THIS_DIR>/server:<THIS_DIR>/client
     17 $ python
     18 >>> import server
     19 >>> import chromedriver
     20 >>> cd_server = server.Server('/path/to/chromedriver/executable')
     21 >>> driver = chromedriver.ChromeDriver(cd_server.GetUrl())
     22 >>> driver.Load('http://www.google.com')
     23 >>> driver.Quit()
     24 >>> cd_server.Kill()
     25 
     26 ChromeDriver will use the system installed Chrome by default.
     27 
     28 To use ChromeDriver2 with Chrome on Android pass the Android package name in the
     29 chromeOptions.androidPackage capability when creating the driver. The path to
     30 adb_commands.py and the adb tool from the Android SDK must be set in PATH. For
     31 more detailed instructions see the user site.
     32 
     33 =====Architecture=====
     34 ChromeDriver is shipped separately from Chrome. It controls Chrome out of
     35 process through DevTools. ChromeDriver is a standalone server which
     36 communicates with the WebDriver client via the WebDriver wire protocol, which
     37 is essentially synchronous JSON commands over HTTP. WebDriver clients are
     38 available in many languages, and many are available from the open source
     39 selenium/webdriver project: http://code.google.com/p/selenium. ChromeDriver
     40 uses the webserver from net/server.
     41 
     42 ChromeDriver has a main thread, called the command thread, an IO thread,
     43 and a thread per session. The webserver receives a request on the IO thread,
     44 which is sent to a handler on the command thread. The handler executes the
     45 appropriate command function, which completes asynchronously. The create
     46 session command may create a new thread for subsequent session-related commands,
     47 which will execute on the dedicated session thread synchronously. When a
     48 command is finished, it will invoke a callback, which will eventually make its
     49 way back to the IO thread as a HTTP response for the server to send.
     50 
     51 =====Code structure (relative to this file)=====
     52 1) .
     53 Implements chromedriver commands.
     54 
     55 2) chrome/
     56 A basic interface for controlling Chrome. Should not depend on or reference
     57 WebDriver-related code or concepts.
     58 
     59 3) js/
     60 Javascript helper scripts.
     61 
     62 4) net/
     63 Code to deal with network communication, such as connection to DevTools.
     64 
     65 5) client/
     66 Code for a python client.
     67 
     68 6) server/
     69 Code for the chromedriver server.
     70 A python wrapper to the chromedriver server.
     71 
     72 7) extension/
     73 An extension used for automating the desktop browser.
     74 
     75 8) test/
     76 Integration tests.
     77 
     78 9) third_party/
     79 Third party libraries used by chromedriver.
     80 
     81 =====Testing=====
     82 See the ChromeDriver waterfall at:
     83     http://build.chromium.org/p/chromium.chromedriver/waterfall
     84 There are 4 test suites for verifying ChromeDriver's correctness:
     85 
     86 1) chromedriver_unittests (chrome/chrome_tests.gypi)
     87 This is the unittest target, which runs on the main waterfall on win/mac/linux
     88 and can close the tree. It is also run on the commit queue and try bots by
     89 default. Tests should take a few milliseconds and be very stable.
     90 
     91 2) chromedriver_tests (chrome/chrome_tests.gypi)
     92 This is a collection of C++ medium sized tests which can be run optionally
     93 on the trybots.
     94 
     95 3) python integration tests
     96 Run test/run_py_tests.py --help for more info. These are only run on the
     97 ChromeDriver waterfall.
     98 
     99 4) WebDriver Java acceptance tests
    100 These are integration tests from the WebDriver open source project which can
    101 be run via test/run_java_tests.py. They are only run on the ChromeDriver
    102 bots. Run with --help for more info.
    103 
    104 =====Contributing=====
    105 Find an open issue and submit a patch for review by an individual listed in
    106 the OWNERS file in this directory. Issues are tracked in chromedriver's issue
    107 tracker:
    108     https://code.google.com/p/chromedriver/issues/list
    109