Skip to content

Commit

Permalink
Merge pull request #34 from mreiche/feature/minimal-driver-options
Browse files Browse the repository at this point in the history
Add test for minimal browser options
  • Loading branch information
mreiche authored Aug 18, 2024
2 parents 9218d98 + cfecc83 commit 79674d3
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion test/test_detect_webdriver.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import inject
import pytest
from selenium.webdriver import ChromeOptions

from paf.manager import WebDriverManager
Expand All @@ -21,6 +20,12 @@ def test_hide_webdriver():
request = WebDriverRequest("non-automated")
request.browser = "chrome"
options = ChromeOptions()
options.add_argument("--no-sandbox")
options.add_argument("--disable-gpu")
options.add_argument("--disable-dev-shm-usage")
options.add_argument("--disable-browser-side-navigation")
options.add_argument("disable-infobars")
options.add_argument("--disable-extensions")
options.add_argument("--disable-blink-features=AutomationControlled")
options.add_experimental_option("excludeSwitches", ["enable-automation"])
options.add_experimental_option('useAutomationExtension', False)
Expand Down

0 comments on commit 79674d3

Please sign in to comment.