Releases: seleniumbase/SeleniumBase
Release list
Add a command-line option to disable the Content Security Policy
Add a command-line option to disable the Content Security Policy.
(The CSP may prevent SeleniumBase custom JavaScript abilities from loading on various web pages.)
Fix browser extension loading for PyPI installations
Fix browser extension loading for PyPI installations:
- Include browser extensions as part of PyPI package data
Update ad-blocker rules
Disable the Content Security Policy of websites by default
Disable the Content Security Policy of websites by default (on Chrome and Firefox)
(If running tests on headless Chrome, the existing Content Security Policy will remain.)
Add methods for setting and removing element attributes
Add methods for setting and removing element attributes:
- Add
self.set_attribute(selector, attribute, value) - Add
self.remove_attribute(selector, attribute)
Save exported website tours to the "tours_exported" folder
- Save exported website tours to the "tours_exported" folder
- Update tour examples
- Set flake8 version to 3.7.7
Add a command-line option to archive old log files rather than deleting them
Add a command-line option to archive old log files rather than deleting them.
If the option is set, log files from the latest_logs folder will get moved to the archived_logs folder for storage. Otherwise, any existing logs in the latest_logs folder will be deleted at the start of the next test run.
Usage: (on the command line when running tests)
--archive_logs
Add the ability to save screenshots at the end of tests
Add the ability to save screenshots at the end of tests.
This adds the feature for passing tests. (This feature already existed for failing tests automatically.)
Check the latest_logs folder for the images.
Usage: (on the command line when running tests)
--save_screenshot
The screenshot will be taken right before the browser is closed.
Add "limit" argument to methods that return or click multiple elements
Add "limit" argument to methods that return or click multiple elements.
Updated methods: ("0" means no limit)
self.find_elements(selector, by=By.CSS_SELECTOR, limit=0)self.find_visible_elements(selector, by=By.CSS_SELECTOR, limit=0)self.click_visible_elements(selector, by=By.CSS_SELECTOR, limit=0)
Example:
self.click_visible_elements('[type="checkbox"]', limit=5)
(Click the first 5 visible checkboxes on a page)
Add the ability to set the User-Agent for the browser
Add the ability to set the User-Agent for the browser:
- Usage:
--agent="USER-AGENT STRING"
Example:
pytest user_agent_test.py --agent="Mozilla/5.0 (Nintendo 3DS; U; ; en) Version/1.7412.EU"
Other changes:
- Fix the Docker integration
- Update console scripts for page-object manipulation
- Update several ReadMe files