зеркало из https://github.com/DeGsoft/maui-linux.git
wait for test to finish so it doesn't break later tests (#6562)
This commit is contained in:
Родитель
a169cf7f69
Коммит
2ca5467e3b
|
@ -75,6 +75,7 @@ namespace Xamarin.Forms.Controls.Issues
|
||||||
lst.RefreshCommand = new Command(async () =>
|
lst.RefreshCommand = new Command(async () =>
|
||||||
{
|
{
|
||||||
var newitems = new List<string>();
|
var newitems = new List<string>();
|
||||||
|
newitems.Add("data refreshed");
|
||||||
await Task.Delay(5000);
|
await Task.Delay(5000);
|
||||||
for (int i = 0; i < 1000; i++)
|
for (int i = 0; i < 1000; i++)
|
||||||
{
|
{
|
||||||
|
@ -98,7 +99,13 @@ namespace Xamarin.Forms.Controls.Issues
|
||||||
[Test]
|
[Test]
|
||||||
public void TestIssue1905RefreshShows()
|
public void TestIssue1905RefreshShows()
|
||||||
{
|
{
|
||||||
|
// wait for test to load
|
||||||
|
RunningApp.WaitForElement("btnRefresh");
|
||||||
RunningApp.Screenshot("Should show refresh control");
|
RunningApp.Screenshot("Should show refresh control");
|
||||||
|
|
||||||
|
// wait for test to finish so it doesn't keep working
|
||||||
|
// in the background and break the next test
|
||||||
|
RunningApp.WaitForElement("data refreshed");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче