Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

All-in-one framework for web automation, end-to-end testing, and website tours. SeleniumBase uses [pytest](https://pytest.org) for running Python scripts, while using [Selenium WebDriver](https://selenium.dev/) for controlling web browsers.

* Fast & Reliable [Python methods](https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/method_summary.md).
* Fast, Reliable [Python methods](https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/method_summary.md).
* Flexible [command-line options](https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/customizing_test_runs.md).
* Includes web & mobile testing.
* Includes a [website tour builder](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/tour_examples/ReadMe.md).
Expand Down Expand Up @@ -92,7 +92,7 @@ self.save_screenshot(FILE_NAME) # Save a screenshot of the current page
```
For the complete list of SeleniumBase methods, see: **[help_docs/method_summary.md](https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/method_summary.md)**

[<img src="https://cdn2.hubspot.net/hubfs/100006/images/sb_logo_dh.png" title="SeleniumBase" align="center" height="145">](https://github.com/seleniumbase/SeleniumBase/blob/master/README.md)
[<img src="https://cdn2.hubspot.net/hubfs/100006/images/sb_logo_dh.png" title="SeleniumBase" align="center" height="155">](https://github.com/seleniumbase/SeleniumBase/blob/master/README.md)

## <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3a.png" title="SeleniumBase" height="32"> Learn More:

Expand All @@ -102,11 +102,14 @@ SeleniumBase automatically handles common WebDriver actions such as spinning up
#### **Simplified code:**<br />
SeleniumBase uses simple syntax for commands, such as:
```python
self.update_text("textarea", "text")
self.update_text("input", "dogs\n")
```
The same command with regular WebDriver is very messy:
(<i>And it doesn't include SeleniumBase smart-waiting.</i>)
```python
self.driver.find_element_by_css_selector("textarea").send_keys("text")
self.driver.find_element_by_css_selector("input").clear() # Not always needed
self.driver.find_element_by_css_selector("input").send_keys("dogs")
self.driver.find_element_by_css_selector("input").submit()
```
(<i>You can still use ``self.driver`` in your code.</i>)

Expand Down
6 changes: 3 additions & 3 deletions examples/ReadMe.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,14 @@ Run an example test in Headless Mode: (invisible web browser)
pytest my_first_test.py --headless
```

Run tests with verbose output per test: (improves logging)
Run tests with verbose output: (includes more details)
```bash
pytest test_suite.py -v
```

Run tests multi-threaded using [n] threads:
```bash
pytest test_suite.py -n=4
pytest test_suite.py -v -n=4
```

Run a parameterized test, which generates multiple tests out of one:
Expand All @@ -47,7 +47,7 @@ pytest parameterized_test.py -v

Run an example test suite and generate a pytest report: (pytest-only)
```bash
pytest test_suite.py --html=report.html
pytest test_suite.py -v --html=report.html
```

Run a failing test: (See the ``latest_logs/`` folder for logs and screenshots)
Expand Down
2 changes: 1 addition & 1 deletion help_docs/features_list.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<a id="feature_list"></a>
## <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3a.png" title="SeleniumBase" height="32"> **Features:**
* A complete test automation framework for building & running reliable testing scripts.
* Uses [Pytest](https://docs.pytest.org/en/latest/) and [Nose](http://nose.readthedocs.io/en/latest/) runners for test discovery, organization, execution, and logging.
* Uses [Pytest](https://docs.pytest.org/en/latest/) or [Nose](http://nose.readthedocs.io/en/latest/) runners for test discovery, organization, execution, and logging.
* Includes [console scripts](https://github.com/seleniumbase/SeleniumBase/blob/master/seleniumbase/console_scripts/ReadMe.md) that save you time by installing web drivers automatically, etc.
* Includes a [website tour builder](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/tour_examples/ReadMe.md) for creating and running walkthroughs on any website.
* Works on multiple platforms such as macOS, Windows, Linux, and [Docker](https://github.com/seleniumbase/SeleniumBase/blob/master/integrations/docker/ReadMe.md).
Expand Down
40 changes: 12 additions & 28 deletions help_docs/method_summary.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,7 @@ For backwards compatibility, older versions of method names have remained to kee

```python
self.open(url)

self.open_url(url)

self.get(url)

self.visit(url)
# Duplicates: self.open_url(url), self.get(url), self.visit(url)

self.click(selector, by=By.CSS_SELECTOR, timeout=None, delay=0)

Expand All @@ -22,29 +17,23 @@ self.double_click(selector, by=By.CSS_SELECTOR, timeout=None)

self.click_chain(selectors_list, by=By.CSS_SELECTOR, timeout=None, spacing=0)

self.type(selector, text, by=By.CSS_SELECTOR, timeout=None, retry=False)

self.input(selector, text, by=By.CSS_SELECTOR, timeout=None, retry=False)

self.update_text(selector, new_value, by=By.CSS_SELECTOR, timeout=None, retry=False)
# Duplicates: self.type(selector, text, by=By.CSS_SELECTOR, timeout=None, retry=False)
# self.input(selector, text, by=By.CSS_SELECTOR, timeout=None, retry=False)

self.add_text(selector, text, by=By.CSS_SELECTOR, timeout=None)

self.send_keys(selector, text, by=By.CSS_SELECTOR, timeout=None)
# Duplicates: self.send_keys(selector, text, by=By.CSS_SELECTOR, timeout=None)

self.submit(selector, by=By.CSS_SELECTOR)

self.refresh_page()

self.refresh()
self.refresh() # Also self.refresh_page()

self.get_current_url()

self.get_page_source()

self.get_page_title()

self.get_title()
# Duplicates: self.get_page_title()

self.go_back()

Expand All @@ -70,9 +59,8 @@ self.get_link_text_attribute(link_text, attribute, hard_fail)

self.get_partial_link_text_attribute(link_text, attribute, hard_fail)

self.click_link_text(link_text, timeout=None)

self.click_link(link_text, timeout=None)
# Duplicates: self.click_link_text(link_text, timeout=None)

self.click_partial_link_text(partial_link_text, timeout=None)

Expand Down Expand Up @@ -333,9 +321,8 @@ self.generate_traffic_chain(pages, loops=1)

self.wait_for_element_present(selector, by=By.CSS_SELECTOR, timeout=None)

self.wait_for_element_visible(selector, by=By.CSS_SELECTOR, timeout=None)

self.wait_for_element(selector, by=By.CSS_SELECTOR, timeout=None)
# Duplicates: self.wait_for_element_visible(selector, by=By.CSS_SELECTOR, timeout=None)

self.get_element(selector, by=By.CSS_SELECTOR, timeout=None)

Expand All @@ -344,17 +331,15 @@ self.assert_element_present(selector, by=By.CSS_SELECTOR, timeout=None)
self.find_element(selector, by=By.CSS_SELECTOR, timeout=None)

self.assert_element(selector, by=By.CSS_SELECTOR, timeout=None)

self.assert_element_visible(selector, by=By.CSS_SELECTOR, timeout=None)
# Duplicates: self.assert_element_visible(selector, by=By.CSS_SELECTOR, timeout=None)

########

self.wait_for_text_visible(text, selector="html", by=By.CSS_SELECTOR, timeout=None)
self.wait_for_text(text, selector="html", by=By.CSS_SELECTOR, timeout=None)
# Duplicates: self.wait_for_text_visible(text, selector="html", by=By.CSS_SELECTOR, timeout=None)

self.wait_for_exact_text_visible(text, selector="html", by=By.CSS_SELECTOR, timeout=None)

self.wait_for_text(text, selector="html", by=By.CSS_SELECTOR, timeout=None)

self.find_text(text, selector="html", by=By.CSS_SELECTOR, timeout=None)

self.assert_text_visible(text, selector="html", by=By.CSS_SELECTOR, timeout=None)
Expand All @@ -369,9 +354,8 @@ self.wait_for_link_text_present(link_text, timeout=None)

self.wait_for_partial_link_text_present(link_text, timeout=None)

self.wait_for_link_text_visible(link_text, timeout=None)

self.wait_for_link_text(link_text, timeout=None)
# Duplicates: self.wait_for_link_text_visible(link_text, timeout=None)

self.find_link_text(link_text, timeout=None)

Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ selenium==3.141.0
pluggy>=0.13.1
attrs>=19.3.0
pytest>=4.6.7;python_version<"3"
pytest>=5.3.1;python_version>="3"
pytest>=5.3.2;python_version>="3"
pytest-cov>=2.8.1
pytest-forked>=1.1.3
pytest-html==1.22.1;python_version<"3.6"
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@

setup(
name='seleniumbase',
version='1.34.2',
version='1.34.3',
description='Fast, Easy, and Reliable Browser Automation & Testing.',
long_description=long_description,
long_description_content_type='text/markdown',
Expand Down Expand Up @@ -96,7 +96,7 @@
'pluggy>=0.13.1',
'attrs>=19.3.0',
'pytest>=4.6.7;python_version<"3"', # For Python 2 compatibility
'pytest>=5.3.1;python_version>="3"',
'pytest>=5.3.2;python_version>="3"',
'pytest-cov>=2.8.1',
'pytest-forked>=1.1.3',
'pytest-html==1.22.1;python_version<"3.6"',
Expand Down