Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4c9eb4e

Browse files
committed
Set max line length to 79
1 parent ea23c18 commit 4c9eb4e

File tree

10 files changed

+315
-332
lines changed

10 files changed

+315
-332
lines changed

README.rst

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,14 @@ https://selenium-python.readthedocs.io
55

66
NOTE: THIS IS NOT AN OFFICIAL DOCUMENTATION
77

8-
This is not an official documentation. If you would like to
9-
contribute to this documentation, you can `fork this project in
10-
GitHub and send pull requests
11-
<https://github.com/baijum/selenium-python>`_. You can also send
12-
your feedback to my email: baiju.m.mail AT gmail DOT com. So far
13-
50+ community members have contributed to this project
14-
(See the closed pull requests). I encourage contributors to add
15-
more sections and make it an awesome documentation! If you know any
16-
translation of this document, please send a PR to update the
17-
below list.
8+
This is not an official documentation. If you would like to contribute to this
9+
documentation, you can `fork this project in GitHub and send pull requests
10+
<https://github.com/baijum/selenium-python>`_. You can also send your feedback
11+
to my email: baiju.m.mail AT gmail DOT com. So far 50+ community members have
12+
contributed to this project (See the closed pull requests). I encourage
13+
contributors to add more sections and make it an awesome documentation! If you
14+
know any translation of this document, please send a PR to update the below
15+
list.
1816

1917
**Translations:**
2018

source/api.rst

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ WebDriver API
55

66
.. note::
77

8-
This is not an official documentation. Official API documentation
9-
is available `here
8+
This is not an official documentation. Official API documentation is
9+
available `here
1010
<https://seleniumhq.github.io/selenium/docs/api/py/api.html>`_.
1111

1212
This chapter covers all the interfaces of Selenium WebDriver.
@@ -46,8 +46,7 @@ with the actual class name given below)::
4646
**Conventions used in the API**
4747

4848
Some attributes are callable (or methods) and others are non-callable
49-
(properties). All the callable attributes are ending with round
50-
brackets.
49+
(properties). All the callable attributes are ending with round brackets.
5150

5251
Here is an example for property:
5352

source/faq.rst

Lines changed: 23 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -26,32 +26,31 @@ Does Selenium 2 support XPath 2.0 ?
2626

2727
Ref: http://seleniumhq.org/docs/03_webdriver.html#how-xpath-works-in-webdriver
2828

29-
Selenium delegates XPath queries down to the browser's own XPath
30-
engine, so Selenium support XPath supports whatever the browser
31-
supports. In browsers which don't have native XPath engines (IE
32-
6,7,8), Selenium supports XPath 1.0 only.
29+
Selenium delegates XPath queries down to the browser's own XPath engine, so
30+
Selenium support XPath supports whatever the browser supports. In browsers
31+
which don't have native XPath engines (IE 6,7,8), Selenium supports XPath 1.0
32+
only.
3333

3434

3535
How to scroll down to the bottom of a page ?
3636
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3737

3838
Ref: http://blog.varunin.com/2011/08/scrolling-on-pages-using-selenium.html
3939

40-
You can use the `execute_script` method to execute javascript on the
41-
loaded page. So, you can call the JavaScript API to scroll to the
42-
bottom or any other position of a page.
40+
You can use the `execute_script` method to execute javascript on the loaded
41+
page. So, you can call the JavaScript API to scroll to the bottom or any other
42+
position of a page.
4343

4444
Here is an example to scroll to the bottom of a page::
4545

4646
driver.execute_script("window.scrollTo(0, document.body.scrollHeight);")
4747

48-
The `window <http://www.w3schools.com/jsref/obj_window.asp>`_ object
49-
in DOM has a `scrollTo
50-
<http://www.w3schools.com/jsref/met_win_scrollto.asp>`_ method to
48+
The `window <http://www.w3schools.com/jsref/obj_window.asp>`_ object in DOM has
49+
a `scrollTo <http://www.w3schools.com/jsref/met_win_scrollto.asp>`_ method to
5150
scroll to any position of an opened window. The `scrollHeight
52-
<http://www.w3schools.com/jsref/dom_obj_all.asp>`_ is a common
53-
property for all elements. The `document.body.scrollHeight` will give
54-
the height of the entire body of the page.
51+
<http://www.w3schools.com/jsref/dom_obj_all.asp>`_ is a common property for all
52+
elements. The `document.body.scrollHeight` will give the height of the entire
53+
body of the page.
5554

5655
How to auto save files using custom Firefox profile ?
5756
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -74,8 +73,8 @@ Another way to find content type is using the `requests
7473
content_type = requests.head('http://www.python.org').headers['content-type']
7574
print(content_type)
7675

77-
Once the content type is identified, you can use it to set the firefox
78-
profile preference: ``browser.helperApps.neverAsk.saveToDisk``
76+
Once the content type is identified, you can use it to set the firefox profile
77+
preference: ``browser.helperApps.neverAsk.saveToDisk``
7978

8079
Here is an example::
8180

@@ -94,24 +93,24 @@ Here is an example::
9493
browser.get("http://pypi.python.org/pypi/selenium")
9594
browser.find_element_by_partial_link_text("selenium-2").click()
9695

97-
In the above example, ``application/octet-stream`` is used as the
98-
content type.
96+
In the above example, ``application/octet-stream`` is used as the content type.
9997

100-
The ``browser.download.dir`` option specify the directory where you
101-
want to download the files.
98+
The ``browser.download.dir`` option specify the directory where you want to
99+
download the files.
102100

103101
How to upload files into file inputs ?
104102
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
105103

106-
Select the ``<input type="file">`` element and call the ``send_keys()`` method passing
107-
the file path, either the path relative to the test script, or an absolute path.
108-
Keep in mind the differences in path names between Windows and Unix systems.
104+
Select the ``<input type="file">`` element and call the ``send_keys()`` method
105+
passing the file path, either the path relative to the test script, or an
106+
absolute path. Keep in mind the differences in path names between Windows and
107+
Unix systems.
109108

110109
How to use firebug with Firefox ?
111110
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
112111

113-
First download the Firebug XPI file, later you call the
114-
``add_extension`` method available for the firefox profile::
112+
First download the Firebug XPI file, later you call the ``add_extension`` method
113+
available for the firefox profile::
115114

116115
from selenium import webdriver
117116

0 commit comments

Comments
 (0)