Skip to content

Commit

Permalink
fix(tests): Fix When_Scrolling_Updates_After_Backspace on macOS/skia
Browse files Browse the repository at this point in the history
  • Loading branch information
spouliot committed Nov 4, 2024
1 parent 2316d6c commit 20df9bd
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -859,9 +859,11 @@ public async Task When_Scrolling_Updates_After_Backspace()
Assert.AreEqual(svRight, LayoutInformation.GetLayoutSlot(SUT).Right);
}

// on macOS we use `option` (menu/alt) + `delete` to remove word at the left
var mod = OperatingSystem.IsMacOS() ? VirtualKeyModifiers.Menu : VirtualKeyModifiers.Control;
for (var i = 0; i < 10; i++)
{
SUT.SafeRaiseEvent(UIElement.KeyDownEvent, new KeyRoutedEventArgs(SUT, VirtualKey.Back, VirtualKeyModifiers.Control));
SUT.SafeRaiseEvent(UIElement.KeyDownEvent, new KeyRoutedEventArgs(SUT, VirtualKey.Back, mod));
}
await WindowHelper.WaitForIdle();

Expand Down

0 comments on commit 20df9bd

Please sign in to comment.