You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A complete framework for web & mobile automation, end-to-end testing, and [website tours](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/tour_examples/ReadMe.md). SeleniumBase uses [pytest](https://docs.pytest.org/en/latest/index.html)for running Python scripts, while using [Selenium WebDriver](https://selenium.dev/) for controlling web browsers.
5
+
A Python toolkit for easy end-to-end web testing and [site tours](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/tour_examples/ReadMe.md) with [pytest](https://docs.pytest.org/en/latest/index.html)and [Selenium WebDriver](https://selenium.dev/).
(<i>Above: [my_first_test.py](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/my_first_test.py) from [examples/](https://github.com/seleniumbase/SeleniumBase/tree/master/examples) running in Demo Mode, which adds JavaScript for highlighting page actions.</i>)<br />
(<i>Requires [Git](https://git-scm.com/) and [Python](https://www.python.org/downloads/). Optionally, you may want to use a [Python virtual environment](https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/virtualenv_instructions.md) to isolate Python dependencies between projects.</i>)
27
-
28
-
#### Upgrade [pip](https://pypi.org/project/pip/) and [setuptools](https://pypi.org/project/setuptools/):
26
+
* Requires **[Python](https://www.python.org/downloads/)** and **[Git](https://git-scm.com/)**
* A [Python virtual env](https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/) is recommended. <i>[See shortcut](https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/virtualenv_instructions.md).</i>
29
+
* Upgrade **[pip](https://pypi.org/project/pip/)** to prevent warnings:
If multiple versions of Python are installed, be specific (E.g. use ``python3`` instead of ``python``).
49
43
44
+
* You can also install ``seleniumbase`` from [pypi](https://pypi.python.org/pypi/seleniumbase):
45
+
```bash
46
+
pip install seleniumbase
47
+
```
48
+
* Add ``--upgrade`` OR ``-U`` to upgrade an installation.
49
+
* Add ``--force-reinstall`` for a clean install.
50
+
50
51
### <imgsrc="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3a.png"title="SeleniumBase"height="32"> Download a webdriver:
51
52
52
53
SeleniumBase can download a webdriver to the [seleniumbase/drivers](https://github.com/seleniumbase/SeleniumBase/tree/master/seleniumbase/drivers) folder with the ``install`` command:
@@ -67,9 +68,11 @@ pytest my_first_test.py
67
68
* Chrome is the default browser if not specified with ``--browser=BROWSER``.
68
69
* On Linux ``--headless`` is the default behavior (running with no GUI). You can also run in headless mode on any OS. If your Linux machine has a GUI and you want to see the web browser as tests run, add ``--headed`` or ``--gui``.
69
70
70
-
**Check out [my_first_test.py](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/my_first_test.py) to see what a simple test looks like:**
71
-
* <i>By default, [CSS Selectors](https://www.w3schools.com/cssref/css_selectors.asp) are used for finding page elements.</i>
72
-
* Here are some common SeleniumBase methods you might find in tests:
71
+
**Check out [my_first_test.py](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/my_first_test.py) to see what a script looks like:**
72
+
<imgsrc="https://cdn2.hubspot.net/hubfs/100006/my_first_test_py_4.png"title="My First SeleniumBase Test"><br />
73
+
* By default, **[CSS Selectors](https://www.w3schools.com/cssref/css_selectors.asp)** are used for finding page elements.
74
+
* If you're new to CSS Selectors, games like [Flukeout](http://flukeout.github.io/) can help you learn.
75
+
* Here are some common ``SeleniumBase`` methods you might find in tests:
73
76
```python
74
77
self.open(URL) # Navigate to the web page
75
78
self.click(SELECTOR) # Click a page element
@@ -654,8 +657,8 @@ Additionally, you can use the ``@retry_on_exception()`` decorator to specificall
654
657
655
658
**If you see something, say something!**<br />[<imgsrc="https://img.shields.io/github/issues-closed-raw/seleniumbase/SeleniumBase.svg?color=22BB88"alt="" />](https://github.com/seleniumbase/SeleniumBase/issues?q=is%3Aissue+is%3Aclosed)[<imgsrc="https://img.shields.io/github/issues-pr-closed/seleniumbase/SeleniumBase.svg?logo=github&logoColor=white&color=22BB99">](https://github.com/seleniumbase/SeleniumBase/pulls?q=is%3Apr+is%3Aclosed)
656
659
660
+
**If you like us, give us a star!**<br />[<imgsrc="https://img.shields.io/github/stars/seleniumbase/seleniumbase.svg?color=777CFA"alt="" />](https://github.com/seleniumbase/SeleniumBase/stargazers)
0 commit comments