Releases: seleniumbase/SeleniumBase
Reliability and other improvements
Reliability and other improvements
- Improve Demo Mode reliability on sites with restrictive CSPs.
- Improve Safari reliability on the
self.open_new_window()
method. - Update default driver versions used and displayed:
-- Use Edgedriver "89.0.774.54" if cannot detect LATEST_STABLE
-- Use Operadriver "v.88.0.4324.104" as the default version - Improve
self.assert_downloaded_file(file)
. - When reusing a session, only keep the first tab/window open.
- Update Python dependencies:
--setuptools-scm==5.0.2;python_version<"3.6"
--setuptools-scm>=6.0.1;python_version>="3.6"
-- Dropallure-pytest
from installed dependencies
Update Python dependencies
Update Python dependencies
ipdb==0.13.7;python_version>="3.6"
urllib3==1.26.4
virtualenv>=20.4.3
Updates for ChartMaker, Traffic-generator, refactoring, and more
Updates for ChartMaker, Traffic-generator, refactoring, and more
- Updates for ChartMaker:
-- Add parameters for enabling/disabling labels & legends on charts.
-- Improve some layout and design details for chart generation. - Updates for Traffic-generator methods:
-- Add parameters to traffic-gen code for lowering the bounce-rate.
---- (Lets you perform a click action as part of traffic-gen methods.) - Make sure that generated presentations include a progress bar.
-- (This was probably already the default option if not changed.) - Refactoring:
-- Move coverage and flake dependencies into ownsetup.py
area.
---- (Install coverage tools with:pip install -e .[coverage]
)
---- (Install flake tools with:pip install -e .[flake]
) - Update required and optional Python dependencies:
--setuptools>=54.1.2;python_version>="3.6"
--prompt-toolkit==3.0.17;python_version>="3.6"
--flake8==3.9.0;python_version>="3.5"
--pyflakes==2.3.0;python_version>="3.5"
--pycodestyle==2.7.0;python_version>="3.5"
SeleniumBase ChartMaker lets you use Python to generate HTML charts from HighCharts JS.
Here's an example: https://github.com/seleniumbase/SeleniumBase/blob/master/examples/chart_maker/chart_presentation.py
SeleniumBase Traffic-generator methods let you generate traffic to a website for testing analytics software that monitors referral sources.
This works by using JavaScript to create a button on a website, which is then clicked in order to take you to a destination page. Website analytics software is easily fooled and believes this traffic to be a genuine referral from the origin website.
self.generate_referral(start_page, destination_page, selector=None)
self.generate_traffic(start_page, destination_page, loops=1, selector=None)
self.generate_referral_chain(pages)
self.generate_traffic_chain(pages, loops=1)
If a selector
is provided in the self.generate_referral
and self.generate_traffic
methods, then the automation will click that button after reaching the destination site. This can prevent an artificial rise in website bounce-rate because the new user performs an action (and therefore doesn't count as a bounce anymore because the user visits a different page of that destination website).
Add method, update console scripts, and update dependencies
Add method, update console scripts, and update dependencies
- Add a new method:
self.is_element_enabled(selector)
:
-- Use this to check if a button or other element is enabled.
-- Add language translations forself.is_element_enabled
- Update console scripts:
--sbase mkpres FILE.py
generates a fancier presentation. - Update Python dependencies:
--ipdb==0.13.6;python_version>="3.6"
--pygments==2.8.1;python_version>="3.5"
Update options, tours, dependencies, and more
Update options, tours, dependencies, and more
- Add the
--interval=SECONDS
option for autoplaying tour steps:
-- (This effects tours, presentations, and chart displays) - Update SeleniumBase tours that use the bootstrap-tour library:
-- (This changes the overall appearance when running tours) - Update the Ad-Block list:
-- New entry:[aria-label="Ads"]
- Update Python dependencies:
--setuptools>=54.1.1;python_version>="3.6"
--Pillow==8.1.2;python_version>="3.6"
--rich==9.13.0;python_version>="3.6"
Improve "--reuse-session" / "--rs" mode
Improve --reuse-session
/ --rs
mode
- If the shared session is closed early, share the next session.
- Update a Python dependency:
--setuptools>=54.1.0;python_version>="3.6"
Fix a method that finds unique links on a page
Fix a method that finds unique links on a page
- Fix
self.get_unique_links()
:
-- (Links where thesrc
starts with./
weren't being processed correctly.)
-- This also fixes impacted methods such asself.assert_no_404_errors()
- Also update a Python dependency:
--setuptools-scm>=5.0.2
Improve reliability of asserting that there are no 404-errors
Improve reliability of asserting that there are no 404-errors
- Improve the results of
self.assert_no_404_errors()
- Also update a Python dependency:
--allure-pytest==2.8.36;python_version>="3.5"
Allow the "choose_file()" method to work on hidden "input" fields
Allow the choose_file()
method to work on hidden "input" fields
- (The
choose_file()
method lets you upload a file to a website using a file-picker.)
Example usage:
self.choose_file(selector, file_path)
self.choose_file('input[type="file"]', "my_dir/my_file.txt")
See https://github.com/seleniumbase/SeleniumBase/blob/master/examples/upload_file_test.py for an example test that uses this method.
Fix the pie chart on pytest html reports for path changes
Fix the dashboard pie chart on pytest html reports for path changes:
- The pie chart from the dashboard should now appear on pytest html reports when changing the folder location of the html report.
-- (For the pie chart to appear on html reports, both the--html=REPORTPATH.html
and the--dashboard
arguments must be used when callingpytest
)
Also update Python dependencies:
ipdb==0.13.5;python_version>="3.6"
Pillow==8.1.1;python_version>="3.6"
rich==9.12.4;python_version>="3.6"
allure-pytest==2.8.35;python_version>="3.5"