Skip to content

Commit

Permalink
ci: Work around msedgedriver 115+ bug (shaka-project#5618)
Browse files Browse the repository at this point in the history
Specify the explicit path to microsoft-edge on Linux if found, to work around MicrosoftEdge/EdgeWebDriver#102 (comment)

This also incorporates
shaka-project/webdriver-installer#35, shaka-project/karma-local-wd-launcher#60, and shaka-project/karma-local-wd-launcher#62 to revert earlier workarounds and apply new ones for local test runs.
# Conflicts:
#	build/shaka-lab.yaml
#	package-lock.json
#	package.json
  • Loading branch information
joeyparrish authored and echoy-harmonicinc committed Sep 27, 2023
1 parent 76cc6c8 commit e897e94
Show file tree
Hide file tree
Showing 3 changed files with 120 additions and 42 deletions.
39 changes: 37 additions & 2 deletions build/shaka-lab.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,31 @@ vars:
excludeSwitches:
- "disable-component-update"

chrome_android_config: &chrome_android_config
basic_edge_config: &basic_edge_config
ms:edgeOptions:
args:
# Normally, Edge disallows autoplaying videos in many cases. Enable it
# for testing.
- "--autoplay-policy=no-user-gesture-required"
# Disable browser features that try to save power by suspending media,
# throttling timers, etc.
- "--disable-background-media-suspend"
- "--disable-background-timer-throttling"
- "--disable-backgrounding-occluded-windows"

# Instruct edgedriver not to disable component updater. The component
# updater must run in order for the Widevine CDM to be available when
# using a new user-data-dir.
excludeSwitches:
- "disable-component-update"

# Work around https://github.com/MicrosoftEdge/EdgeWebDriver/issues/102#issuecomment-1710724173
# by specifying the binary path on Linux.
edge_linux_config: &edge_linux_config
ms:edgeOptions:
binary: /usr/bin/microsoft-edge

android_chrome_config: &android_chrome_config
goog:chromeOptions:
args: *minimum_chrome_android_args

Expand Down Expand Up @@ -137,7 +161,18 @@ ChromeLinux:
FirefoxLinux:
browser: firefox
os: Linux
extra_config: *firefox_config
extra_configs:
- *basic_firefox_config

EdgeLinux:
browser: msedge
os: Linux
extra_configs:
- *basic_edge_config
- *edge_linux_config


### Misc ###

ChromeAndroid:
browser: chrome
Expand Down
121 changes: 82 additions & 39 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"karma-coverage": "^2.2.0",
"karma-jasmine": "^4.0.1",
"karma-jasmine-ajax": "^0.1.13",
"karma-local-wd-launcher": "^1.6.1",
"karma-local-wd-launcher": "^1.6.6",
"karma-opera-launcher": "^1.0.0",
"karma-sourcemap-loader": "^0.3.8",
"karma-spec-reporter": "^0.0.34",
Expand Down

0 comments on commit e897e94

Please sign in to comment.