From 1d85238195c557eece9d9c589773374a544289f4 Mon Sep 17 00:00:00 2001 From: Michael Mintz Date: Sat, 17 Sep 2022 22:21:39 -0400 Subject: [PATCH] Update the documentation --- README.md | 6 ++---- examples/tour_examples/ReadMe.md | 2 +- help_docs/demo_mode.md | 35 ++++++++++++++++++++++++++++++++ help_docs/js_package_manager.md | 8 ++++---- mkdocs.yml | 1 + 5 files changed, 43 insertions(+), 9 deletions(-) create mode 100755 help_docs/demo_mode.md diff --git a/README.md b/README.md index 24fec32f..fe23afb7 100755 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ -

SeleniumBase

+

SeleniumBase

Scale your web app testing with Selenium, Python, and pytest.

PyPI version GitHub version SeleniumBase Docs SeleniumBase GitHub Actions SeleniumBase

@@ -59,11 +59,9 @@ pytest test_demo_site.py --chrome

SeleniumBase Example

- -------- -

Run test_swag_labs.py from examples/ in Demo Mode (highlights browser actions):

- +

Run test_swag_labs.py from examples/ using Demo Mode (highlights browser actions):

```bash pytest test_swag_labs.py --demo diff --git a/examples/tour_examples/ReadMe.md b/examples/tour_examples/ReadMe.md index d65395fd..ca879c01 100755 --- a/examples/tour_examples/ReadMe.md +++ b/examples/tour_examples/ReadMe.md @@ -1,6 +1,6 @@

SeleniumBase Tour

-## [](https://github.com/seleniumbase/SeleniumBase/) Interactive Product Tours +## [](https://github.com/seleniumbase/SeleniumBase/) Interactive Product Tours 🚎

Increase SaaS Product Adoption by 10x or more.

diff --git a/help_docs/demo_mode.md b/help_docs/demo_mode.md new file mode 100755 index 00000000..91698acc --- /dev/null +++ b/help_docs/demo_mode.md @@ -0,0 +1,35 @@ +## [](https://github.com/seleniumbase/SeleniumBase/) Demo Mode 🎦 + +

SeleniumBase Example

+ +Use ``--demo`` to run SeleniumBase tests with Demo Mode enabled, which highlights browser actions and shows visual assertions. + +-------- + +

Here's how to run test_swag_labs.py from examples/ in Demo Mode:

+ + +```bash +pytest test_swag_labs.py --demo +``` + +

SeleniumBase Example

+ +-------- + +

Here's an example that only uses the highlight() method for highlighting browser actions:

+ + +

(test_error_page.py from examples/)

+ +```bash +pytest test_error_page.py +``` + +

SeleniumBase Example

+ +-------- + +Here's an example of a mobile test in Demo Mode: + +

SeleniumBase Example

diff --git a/help_docs/js_package_manager.md b/help_docs/js_package_manager.md index 28be5ece..d7744725 100755 --- a/help_docs/js_package_manager.md +++ b/help_docs/js_package_manager.md @@ -4,7 +4,7 @@ 🎨 The following SeleniumBase solutions utilize this feature: -πŸ—ΊοΈ Website Tours - 🎞️ Presenter - πŸ“Š Chart Maker - πŸ›‚ Dialog Boxes +🎦 Demo Mode - 🚎 Website Tours - 🎞️ Presenter - πŸ“Ά Chart Maker - πŸ›‚ Dialog Boxes

πŸ•ΉοΈ In addition to loading JS packages, SeleniumBase also lets you generate JS code from Python so that you can use these packages more easily.

@@ -102,11 +102,11 @@ def add_css_link(driver, css_link):
πŸ•ΉοΈ Website tours are just one of the many uses of the JS Package Manager.

πŸ›‚ The following example shows the JqueryConfirm package loaded into a website for creating fancy dialog boxes:

-SeleniumBase +SeleniumBase

↕️ (Example: dialog_box_tour.py) ↕️

-SeleniumBase +SeleniumBase

Here's how to run that example:

@@ -131,4 +131,4 @@ pytest test_dialog_boxes.py SeleniumBase on GitHub -πŸ—ΊοΈ If you're only interested in creating website tours with SeleniumBase, here's the link to the Website Tours ReadMe. +🚎 If you're only interested in creating website tours with SeleniumBase, here's the link to the Website Tours ReadMe. diff --git a/mkdocs.yml b/mkdocs.yml index 31cf0df1..4413f2e0 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -108,6 +108,7 @@ nav: - Chinese Docs: help_docs/chinese.md - Locale Codes: help_docs/locale_codes.md - JS Generators: + - Demo Mode: help_docs/demo_mode.md - Tour Maker: examples/tour_examples/ReadMe.md - Dialog Boxes: examples/dialog_boxes/ReadMe.md - Chart Maker: help_docs/chart_maker.md