Skip to content

Commit b2c1acb

Browse files
committed
Update the ReadMe
1 parent c616424 commit b2c1acb

File tree

1 file changed

+31
-19
lines changed

1 file changed

+31
-19
lines changed

README.md

Lines changed: 31 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,12 @@
88
<img src="https://github.com/seleniumbase/SeleniumBase/workflows/CI%20build/badge.svg" alt="SeleniumBase GitHub Actions" /></a> <a href="https://gitter.im/seleniumbase/SeleniumBase">
99
<img src="https://badges.gitter.im/seleniumbase/SeleniumBase.svg" alt="SeleniumBase" /></a>
1010
</p>
11+
1112
<p align="center">
1213
<div align="center"><span align="center"><b>Create web and mobile tests, fast!</b></span></div>
1314
<div align="center"><span align="center">Take <a href="https://selenium.dev/">Selenium</a> and <a href="https://docs.pytest.org/en/latest/index.html">pytest</a> to the next level.</span></div>
1415
</p>
16+
1517
<p align="center">
1618
<a href="#python_installation">🚀 Get Started</a> |
1719
<a href="https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/customizing_test_runs.md">🧙‍♂️ CMD Options</a> |
@@ -27,17 +29,20 @@
2729
<a href="https://github.com/seleniumbase/SeleniumBase/blob/master/seleniumbase/utilities/selenium_ide/ReadMe.md">⏺️ Recorder</a> |
2830
<a href="https://github.com/seleniumbase/SeleniumBase/blob/master/examples/visual_testing/ReadMe.md">👩‍🎨 Visual Testing</a> |
2931
<a href="https://github.com/seleniumbase/SeleniumBase/blob/master/integrations/github/workflows/ReadMe.md">🤖 GitHub CI</a>
32+
3033
</p>
3134
<p align="center">
3235
<div align="center"><b>Feel good about your test automation.</b></div>
3336
<div align="center">Control builds from the command line.</div>
3437
</p>
38+
3539
<p align="center"><a href="https://github.com/seleniumbase/SeleniumBase/blob/master/examples/test_swag_labs.py"><img src="https://cdn2.hubspot.net/hubfs/100006/images/swag_mobile.gif" /></a></p>
3640
<p align="center">(<i>Above: <a href="https://github.com/seleniumbase/SeleniumBase/blob/master/examples/test_swag_labs.py">test_swag_labs.py</a> running with mobile emulation enabled.</i>)</p>
3741

3842
```bash
3943
pytest test_swag_labs.py --mobile
4044
```
45+
4146
------
4247
<div><p align="center">(<i>Below: Same test as above, but running in Demo Mode now.</i>)</p></div>
4348

@@ -95,7 +100,7 @@ pytest my_first_test.py
95100
* Chrome is the default browser if not specified with ``--browser=BROWSER``.
96101
* 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``.
97102

98-
**Here's an example test, [my_first_test.py](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/my_first_test.py):**<br />
103+
<b>Here's an example test, [my_first_test.py](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/my_first_test.py):</b>
99104
```python
100105
from seleniumbase import BaseCase
101106

@@ -114,7 +119,7 @@ class MyTestClass(BaseCase):
114119
self.update_text("input.search-input", "xkcd book\n")
115120
self.assert_exact_text("xkcd: volume 0", "h3")
116121
```
117-
<img src="https://cdn2.hubspot.net/hubfs/100006/images/my_first_test_gif.gif" title="SeleniumBase" /><br />
122+
<img src="https://cdn2.hubspot.net/hubfs/100006/images/my_first_test_gif.gif" title="SeleniumBase" />
118123
```bash
119124
pytest my_first_test.py --demo
120125
```
@@ -148,10 +153,10 @@ For the complete list of SeleniumBase methods, see: <b><a href="https://github.c
148153

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

151-
#### **Automatic WebDriver abilities:**<br />
156+
#### Automatic WebDriver abilities:
152157
SeleniumBase automatically handles common WebDriver actions such as spinning up web browsers and saving screenshots during test failures. (<i><a href="https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/customizing_test_runs.md">Read more about customizing test runs</a>.</i>)
153158

154-
#### **Simplified code:**<br />
159+
#### Simplified code:
155160
SeleniumBase uses simple syntax for commands, such as:
156161
```python
157162
self.update_text("input", "dogs\n")
@@ -169,7 +174,7 @@ As you can see, the old WebDriver way is very bad!
169174
Use SeleniumBase to make testing much easier!
170175
(<i>You can still use ``self.driver`` in your code.</i>)
171176

172-
#### **Run tests with ``pytest`` or ``nosetests`` in any browser:**<br />
177+
#### Run tests with ``pytest`` or ``nosetests`` in any browser:
173178
(<i>Using **pytest** is recommended. **Chrome** is the default browser.</i>)
174179
```bash
175180
pytest my_first_test.py --browser=chrome
@@ -182,13 +187,13 @@ pytest [FILE_NAME].py::[CLASS_NAME]::[METHOD_NAME]
182187
nosetests [FILE_NAME].py:[CLASS_NAME].[METHOD_NAME]
183188
```
184189

185-
#### **No more flaky tests:**<br />
190+
#### No more flaky tests:
186191
SeleniumBase methods automatically wait for page elements to finish loading before interacting with them (*up to a timeout limit*). This means you no longer need random ``time.sleep()`` statements in your scripts.
187192

188-
#### **Automated/manual hybrid mode:**<br />
193+
#### Automated/manual hybrid mode:
189194
SeleniumBase includes a solution called <b><a href="https://github.com/seleniumbase/SeleniumBase/blob/master/seleniumbase/masterqa/ReadMe.md">MasterQA</a></b>, which speeds up manual testing by having automation perform all the browser actions while the manual tester handles validatation.
190195

191-
#### **Feature-Rich:**<br />
196+
#### Feature-Rich:
192197
For a full list of SeleniumBase features, <a href="https://github.com/seleniumbase/SeleniumBase/blob/master/help_docs/features_list.md">Click Here</a>.
193198

194199

@@ -388,12 +393,12 @@ The ``--report`` option gives you a fancy report after your test suite completes
388393
```bash
389394
nosetests test_suite.py --report
390395
```
391-
<img src="https://cdn2.hubspot.net/hubfs/100006/images/Test_Report_2.png" title="Example Nosetest Report" height="420">
396+
<img src="https://cdn2.hubspot.net/hubfs/100006/images/Test_Report_2.png" title="Example Nosetest Report" height="420" />
392397

393398
(NOTE: You can add ``--show-report`` to immediately display Nosetest reports after the test suite completes. Only use ``--show-report`` when running tests locally because it pauses the test run.)
394399

395400

396-
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32"> **Using a Proxy Server:**
401+
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32" />Using a Proxy Server:
397402

398403
If you wish to use a proxy server for your browser tests (Chrome and Firefox only), you can add ``--proxy=IP_ADDRESS:PORT`` as an argument on the command-line.
399404
```bash
@@ -411,22 +416,22 @@ pytest proxy_test.py --proxy=proxy1
411416
```
412417

413418

414-
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32"> **Changing the User-Agent:**
419+
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32">Changing the User-Agent:
415420

416421
If you wish to change the User-Agent for your browser tests (Chrome and Firefox only), you can add ``--agent="USER AGENT STRING"`` as an argument on the command-line.
417422
```bash
418423
pytest user_agent_test.py --agent="Mozilla/5.0 (Nintendo 3DS; U; ; en) Version/1.7412.EU"
419424
```
420425

421426

422-
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32"> **Building Guided Tours for Websites:**
427+
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32">Building Guided Tours for Websites:
423428

424429
Learn about <a href="https://github.com/seleniumbase/SeleniumBase/blob/master/examples/tour_examples/ReadMe.md">SeleniumBase Interactive Walkthroughs</a> (in the ``examples/tour_examples`` folder). It's great for prototyping a website onboarding experience.
425430

426431
<img src="https://cdn2.hubspot.net/hubfs/100006/google_tour_3.gif" title="SeleniumBase Tour of Google" />
427432

428433
<a id="utilizing_advanced_features"></a>
429-
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32"> **Production Environments & Integrations:**
434+
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32">Production Environments & Integrations:
430435

431436
Here are some things you can do to setup a production environment for your testing:
432437

@@ -448,7 +453,7 @@ pytest [YOUR_TEST_FILE].py --with-db-reporting --with-s3-logging
448453
<img src="https://cdn2.hubspot.net/hubfs/100006/images/sb_media_logo_c.png" title="SeleniumBase" height="100" />
449454

450455
<a id="detailed_method_specifications"></a>
451-
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32"> **Detailed Method Specifications and Examples:**
456+
### <img src="https://cdn2.hubspot.net/hubfs/100006/images/super_square_logo_3.png" title="SeleniumBase" height="32">Detailed Method Specifications and Examples:
452457

453458
#### Navigating to a web page (and related commands)
454459

@@ -466,7 +471,7 @@ self.get_current_url() # This method returns the current page URL.
466471
self.get_page_source() # This method returns the current page source.
467472
```
468473

469-
**ProTip™:** You may need to use the get_page_source() method along with Python's find() command to parse through the source to find something that Selenium wouldn't be able to. (You may want to brush up on your Python programming skills for that.)
474+
<b>ProTip™:</b> You may need to use the get_page_source() method along with Python's find() command to parse through the source to find something that Selenium wouldn't be able to. (You may want to brush up on your Python programming skills for that.)
470475
```python
471476
source = self.get_page_source()
472477
head_open_tag = source.find('<head>')
@@ -718,12 +723,19 @@ Additionally, you can use the ``@retry_on_exception()`` decorator to specificall
718723

719724
#### Congratulations on getting started with SeleniumBase!
720725

721-
**If you see something, say something!**<br />[<img src="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) [<img src="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)
726+
<p>
727+
<div><b>If you see something, say something!</b></div>
728+
<div><a href="https://github.com/seleniumbase/SeleniumBase/issues?q=is%3Aissue+is%3Aclosed"><img src="https://img.shields.io/github/issues-closed-raw/seleniumbase/SeleniumBase.svg?color=22BB88" title="Closed Issues" /></a> <a href="https://github.com/seleniumbase/SeleniumBase/pulls?q=is%3Apr+is%3Aclosed"><img src="https://img.shields.io/github/issues-pr-closed/seleniumbase/SeleniumBase.svg?logo=github&logoColor=white&color=22BB99" title="Closed Pull Requests" /></a></div>
729+
</p>
722730

723-
**If you like us, give us a star!**<br />[<img src="https://img.shields.io/github/stars/seleniumbase/seleniumbase.svg?color=888CFA" alt=" " />](https://github.com/seleniumbase/SeleniumBase/stargazers)
731+
<p>
732+
<div><b>If you like us, give us a star!</b></div>
733+
<div><a href="https://github.com/seleniumbase/SeleniumBase/stargazers"><img src="https://img.shields.io/github/stars/seleniumbase/seleniumbase.svg?color=888CFA" title="Stargazers" /></a></div>
734+
</p>
735+
<p><div><a href="https://github.com/mdmintz">https://github.com/mdmintz</a></div></p>
724736

725-
[https://github.com/mdmintz](https://github.com/mdmintz)<br />
737+
<div><a href="https://github.com/seleniumbase/SeleniumBase/blob/master/README.md"><img src="https://cdn2.hubspot.net/hubfs/100006/images/super_logo_sb.png" title="SeleniumBase" height="46.2" /></a></div>
726738

727-
[<img src="https://cdn2.hubspot.net/hubfs/100006/images/super_logo_sb.png" title="SeleniumBase" height="46.2">](https://github.com/seleniumbase/SeleniumBase/blob/master/README.md) <br /> [<img src="https://img.shields.io/badge/license-MIT-22BBCC.svg" alt=" " />](https://github.com/seleniumbase/SeleniumBase/blob/master/LICENSE) [<img src="https://img.shields.io/github/repo-size/seleniumbase/seleniumbase.svg" alt="Size" />](https://github.com/seleniumbase/SeleniumBase/releases) [<img src="https://badges.gitter.im/seleniumbase/SeleniumBase.svg" alt="Join the chat!" />](https://gitter.im/seleniumbase/SeleniumBase)
739+
<div><a href="https://github.com/seleniumbase/SeleniumBase/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-22BBCC.svg" title="SeleniumBase" /></a> <a href="https://github.com/seleniumbase/SeleniumBase/releases"><img src="https://img.shields.io/github/repo-size/seleniumbase/seleniumbase.svg" title="SeleniumBase" alt="Repo Size" /></a> <a href="https://gitter.im/seleniumbase/SeleniumBase"><img src="https://badges.gitter.im/seleniumbase/SeleniumBase.svg" title="SeleniumBase" alt="Join the chat!" /></a></div>
728740

729741
<a href="https://github.com/seleniumbase/SeleniumBase"><img src="https://img.shields.io/badge/tested%20with-SeleniumBase-04C38E.svg" alt="Tested with SeleniumBase" /></a>

0 commit comments

Comments
 (0)