Skip to content

Commit 243fecc

Browse files
committed
Pass pytest_html_report to base_case.BaseCase
1 parent 971db5d commit 243fecc

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

seleniumbase/fixtures/base_case.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3113,6 +3113,10 @@ def setUp(self, masterqa_mode=False):
31133113
self.save_screenshot_after_test = sb_config.save_screenshot
31143114
self.visual_baseline = sb_config.visual_baseline
31153115
self.timeout_multiplier = sb_config.timeout_multiplier
3116+
self.pytest_html_report = sb_config.pytest_html_report
3117+
self.report_on = False
3118+
if self.pytest_html_report:
3119+
self.report_on = True
31163120
self.use_grid = False
31173121
if self.servername != "localhost":
31183122
# Use Selenium Grid (Use --server=127.0.0.1 for localhost Grid)

seleniumbase/plugins/pytest_plugin.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,7 @@ def pytest_configure(config):
221221
sb_config.save_screenshot = config.getoption('save_screenshot')
222222
sb_config.visual_baseline = config.getoption('visual_baseline')
223223
sb_config.timeout_multiplier = config.getoption('timeout_multiplier')
224+
sb_config.pytest_html_report = config.getoption("htmlpath") # --html=FILE
224225

225226
if sb_config.with_testing_base:
226227
log_helper.log_folder_setup(sb_config.log_path, sb_config.archive_logs)

0 commit comments

Comments
 (0)