Skip to content

Commit 8c70516

Browse files
authored
More fixing of flaky UI tests (#3100)
1 parent 4d0e7e2 commit 8c70516

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

MaterialDesignThemes.UITests/WPF/DialogHosts/DialogHostTests.cs

+5-3
Original file line numberDiff line numberDiff line change
@@ -344,8 +344,10 @@ public async Task DialogHost_WithOpenDialog_ShowsPopupWhenLoaded()
344344

345345
await Wait.For(async () => Assert.True(await closeButton.GetIsVisible()));
346346

347-
await closeButton.LeftClick();
348-
349-
await Wait.For(async () => Assert.False(await dialogHost.GetIsOpen()));
347+
await Wait.For(async () =>
348+
{
349+
await closeButton.LeftClick();
350+
Assert.False(await dialogHost.GetIsOpen());
351+
});
350352
}
351353
}

MaterialDesignThemes.UITests/WPF/PasswordBoxes/PasswordBoxTests.cs

+1
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ public async Task RevealPasswordBox_WithBoundPasswordProperty_RespectsThreeWayBi
105105
string? clearTextPassword1 = await clearTextPasswordTextBox.GetProperty<string>(TextBox.TextProperty);
106106

107107
// Act 2 (Update in RevealPasswordTextBox updates PasswordBox and VM)
108+
await Task.Delay(50);
108109
await revealPasswordButton.LeftClick();
109110
await Task.Delay(50); // Wait for the "clear text TextBox" to become visible
110111
await clearTextPasswordTextBox.SendKeyboardInput($"2");

0 commit comments

Comments
 (0)