From 8ce3c94c456c20dfcc2039195f599ff5772b9fdb Mon Sep 17 00:00:00 2001 From: Michael Mintz Date: Sun, 26 Sep 2021 15:07:03 -0400 Subject: [PATCH] Update the docs --- README.md | 6 +++--- docs/requirements.txt | 4 ++-- help_docs/customizing_test_runs.md | 2 +- help_docs/method_summary.md | 2 ++ help_docs/recorder_mode.md | 13 +++++++++++-- mkdocs.yml | 2 +- seleniumbase/extensions/ReadMe.md | 1 + 7 files changed, 21 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 8bbbe431..a5f0cce1 100755 --- a/README.md +++ b/README.md @@ -23,8 +23,8 @@

πŸš€ Start | πŸ‘¨β€πŸ« Examples | -πŸ§™β€β™‚οΈ Scripts | 🏰 Features | +πŸ§™β€β™‚οΈ Scripts | πŸ–₯️ CLI | πŸ“± Mobile | πŸ–ΌοΈ VisualTest @@ -38,8 +38,8 @@ πŸ•ΉοΈ JSPkgMgr
πŸ€– CI | -🎞️ Present | -♻️ Boilerplate | +🎞️ Slides | +♻️ Boilerplates | 🌏 Translate | πŸ—ΊοΈ Tour | πŸ“Ά Charts | diff --git a/docs/requirements.txt b/docs/requirements.txt index 86c951ed..d5834c58 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -1,4 +1,4 @@ -regex>=2021.8.27 +regex>=2021.9.24 tqdm>=4.62.3 livereload==2.6.3;python_version>="3.6" joblib==1.0.1;python_version>="3.6" @@ -20,7 +20,7 @@ lunr==0.6.0;python_version>="3.6" nltk==3.6.3;python_version>="3.6" watchdog==2.1.5;python_version>="3.6" mkdocs==1.2.2;python_version>="3.6" -mkdocs-material==7.2.8;python_version>="3.6" +mkdocs-material==7.3.0;python_version>="3.6" mkdocs-exclude-search==0.5.2;python_version>="3.6" mkdocs-simple-hooks==0.1.3 mkdocs-material-extensions==1.0.3;python_version>="3.6" diff --git a/help_docs/customizing_test_runs.md b/help_docs/customizing_test_runs.md index 1a5650db..f089365c 100755 --- a/help_docs/customizing_test_runs.md +++ b/help_docs/customizing_test_runs.md @@ -1,4 +1,4 @@ -[](https://github.com/seleniumbase/SeleniumBase/blob/master/README.md) +[](https://github.com/seleniumbase/SeleniumBase/) # pytest CLI Options diff --git a/help_docs/method_summary.md b/help_docs/method_summary.md index b2baf4b6..412f5173 100755 --- a/help_docs/method_summary.md +++ b/help_docs/method_summary.md @@ -199,6 +199,8 @@ self.switch_to_default_content() self.set_content_to_frame(frame, timeout=None) +self.set_content_to_default(nested=True) + self.open_new_window(switch_to=True) self.switch_to_window(window, timeout=None) diff --git a/help_docs/recorder_mode.md b/help_docs/recorder_mode.md index d31bfaa9..475b9c92 100755 --- a/help_docs/recorder_mode.md +++ b/help_docs/recorder_mode.md @@ -1,4 +1,4 @@ -[](https://github.com/seleniumbase/SeleniumBase/blob/master/README.md) +[](https://github.com/seleniumbase/SeleniumBase/)

Recorder Mode

@@ -21,7 +21,14 @@ import ipdb; ipdb.set_trace() πŸ”΄ Once you've reached the breakpoint, you can take control of the browser and add in any actions that you want recorded. When you are finished recording, type "``c``" on the command-line and press ``[Enter]`` to let the test continue from the breakpoint. After the test completes, a file called ``TEST_NAME_rec.py`` will be automatically created in the ``./recordings`` folder, which will include the actions performed by the test, and the manual actions that you added in. Below is a command-line notification: ```bash ->>> RECORDING saved to: recordings/my_first_test_rec.py +>>> RECORDING SAVED as: recordings/my_first_test_rec.py +******************************************************* +``` + +If a Python file contains more tests, they'll be added: + +```bash +>>> RECORDING ADDED to: recordings/my_first_test_rec.py ******************************************************* ``` @@ -49,6 +56,8 @@ class RecorderTest(BaseCase):

πŸ”΄ SeleniumBase 1.66.1 adds the ability to record changes to "Choose File" input fields. Sometimes the "Choose File" input field is hidden on websites, so self.show_file_choosers() was added to get around this edge case. Version 1.66.1 also adds self.set_content_to_frame(frame), which lets you record actions inside of iframes.

+

πŸ”΄ SeleniumBase 1.66.2 adds the ability to save selectors using the ":contains(TEXT)" selector. If a Python file being recorded has multiple tests being run, then all those tests will get saved to the generated "*_rec.py" file. In order to escape iframes when using self.set_content_to_frame(frame), a new method was added: self.set_content_to_default(). The self.set_content_to_*() methods will be automatically used in place of self.switch_to_*() methods in Recorder Mode, unless a test explicitly calls self._rec_overrides_switch = False before the self.switch_to_*() methods are called. Additionally, if an iframe contains the src attribute, that page will get loaded in a new tab when switching to it in Recorder Mode.

+ --------
To learn more about SeleniumBase, check out the Docs Site:
diff --git a/mkdocs.yml b/mkdocs.yml index 6c05b6d7..649e4abf 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -39,7 +39,7 @@ theme: static_templates: - 404.html features: - - search.highlight + # - search.highlight - toc.integrate - navigation.indexes # - navigation.sections diff --git a/seleniumbase/extensions/ReadMe.md b/seleniumbase/extensions/ReadMe.md index 8c2a2189..82553d5d 100755 --- a/seleniumbase/extensions/ReadMe.md +++ b/seleniumbase/extensions/ReadMe.md @@ -3,5 +3,6 @@

SeleniumBase browser extension storage

**The List:** +* ad_block.zip => This extension blocks ad content from appearing on any website. * disable_csp.zip => This extension disables a website's Content-Security-Policy. * recorder.zip => Save browser actions to sessionStorage with good CSS selectors.