Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OSOE-662: BehaviorVueTests is flaky #312

Merged
merged 6 commits into from
Sep 17, 2023
Merged
Show file tree
Hide file tree
Changes from 2 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
6 changes: 4 additions & 2 deletions Lombiq.Tests.UI/Docs/FakeVideoCaptureSource.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,17 @@ _Hint: The `mjpeg` format will usually result in a smaller file size._
ffmpeg -y -i test.mp4 -pix_fmt yuv420p test.y4m

# Convert with resize to 480p.
ffmpeg -y -i test.mp4 -filter:v scale=480:-1 -pix_fmt yuv420p test.y4m
ffmpeg -y -i test.mp4 -vf "scale=480:720" -pix_fmt yuv420p test.y4m

# Convert mp4 to mjpeg.
ffmpeg -y -i test.mp4 test.mjpeg

# Convert with resize to 480p.
ffmpeg -y -i test.mp4 -filter:v scale=480:-1 test.mjpeg
ffmpeg -y -i test.mp4 -vf "scale=480:720" test.mjpeg
```

_Warning: Using the `-filter:v scale=480:-1` command might "ruin" the video, resulting in a black screen in the browser without warnings._
DemeSzabolcs marked this conversation as resolved.
Show resolved Hide resolved

## Sample

You can find a usage example under [Lombiq Vue.js module for Orchard Core - UI Test Extensions](https://github.com/Lombiq/Orchard-Vue.js/tree/dev/Lombiq.VueJs.Tests.UI).
1 change: 1 addition & 0 deletions Lombiq.Tests.UI/Services/WebDriverFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ private static TDriverOptions SetCommonOptions<TDriverOptions>(this TDriverOptio
{
var fakeCameraSourceFilePath = configuration.FakeVideoSource.SaveVideoToTempFolder();

options.AddArgument("disable-gesture-requirement-for-media-playback");
sarahelsaig marked this conversation as resolved.
Show resolved Hide resolved
options.AddArgument("use-fake-device-for-media-stream");
options.AddArgument("use-fake-ui-for-media-stream");
options.AddArgument($"use-file-for-fake-video-capture={fakeCameraSourceFilePath}");
Expand Down