Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,8 @@ def pytest_runtest_setup(item: Item) -> None:
},
)
chrome_options.enable_bidi = True
# https://forum.robotframework.org/t/maximize-window-chromedriver-133/8416/3
chrome_options.browser_version = "132"
chrome_options.add_argument("disable-dev-shm-usage")
chrome_options.add_argument("no-sandbox")
chrome_options.add_argument("allow-file-access-from-files")
Expand Down Expand Up @@ -192,7 +194,7 @@ def pytest_runtest_setup(item: Item) -> None:
case "remote":
chrome_options = webdriver.ChromeOptions()
# https://aerokube.com/images/latest/#_chrome
chrome_options.browser_version = "127.0"
chrome_options.browser_version = "128.0"
Comment on lines 196 to +197
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Consider using dynamic version for remote browser.

Similar to the local browser version, the remote browser version is hardcoded to "128.0".

-# https://aerokube.com/images/latest/#_chrome
-chrome_options.browser_version = "128.0"
+# Use environment variable to allow flexible version configuration
+chrome_options.browser_version = os.getenv("REMOTE_CHROME_VERSION", "latest")
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
# https://aerokube.com/images/latest/#_chrome
chrome_options.browser_version = "127.0"
chrome_options.browser_version = "128.0"
# Use environment variable to allow flexible version configuration
chrome_options.browser_version = os.getenv("REMOTE_CHROME_VERSION", "latest")

chrome_options.set_capability(
"selenoid:options",
{
Expand Down
Loading