Skip to content

Commit 5c2fbcb

Browse files
committed
expo tests added timeout
1 parent cb71d12 commit 5c2fbcb

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

examples/with-javascript-expo/e2e/app.test.js

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,46 +21,46 @@ describe('mobile todo app test', () => {
2121
});
2222

2323
it('should show welcome screen', async () => {
24-
await expect(element(by.text(/cover/i))).toBeVisible();
24+
await waitFor(element(by.text(/cover/i))).toBeVisible().withTimeout(10000);
2525

26-
await expect(element(by.text(/organize your/i))).toBeVisible();
27-
await expect(element(by.text(/tasks with sqlite/i))).toBeVisible();
28-
await expect(element(by.text(/designed for happiness, not just productivity./i))).toBeVisible();
29-
await expect(element(by.text(/enjoy a stress-free way to manage your day./i))).toBeVisible();
26+
await waitFor(element(by.text(/organize your/i))).toBeVisible().withTimeout(10000);
27+
await waitFor(element(by.text(/tasks with sqlite/i))).toBeVisible().withTimeout(10000);
28+
await waitFor(element(by.text(/designed for happiness, not just productivity./i))).toBeVisible().withTimeout(10000);
29+
await waitFor(element(by.text(/enjoy a stress-free way to manage your day./i))).toBeVisible().withTimeout(10000);
3030

31-
await expect(element(by.text(/get started/i))).toBeVisible();
31+
await waitFor(element(by.text(/get started/i))).toBeVisible().withTimeout(10000);
3232
});
3333

3434
it('should get categories from chinook', async () => {
35-
await expect(element(by.text(/get started/i))).toBeVisible();
35+
await waitFor(element(by.text(/get started/i))).toBeVisible().withTimeout(10000);
3636
await element(by.text(/get started/i)).tap();
3737

38-
await expect(element(by.text(/inbox/i))).toBeVisible();
39-
await expect(element(by.text(/work/i))).toBeVisible();
40-
await expect(element(by.text(/personal/i))).toBeVisible();
38+
await waitFor(element(by.text(/inbox/i))).toBeVisible().withTimeout(10000);
39+
await waitFor(element(by.text(/work/i))).toBeVisible().withTimeout(10000);
40+
await waitFor(element(by.text(/personal/i))).toBeVisible().withTimeout(10000);
4141
await waitFor(element(by.text(/expo_ci_do_not_delete/i))).toBeVisible().withTimeout(10000);
4242
});
4343

4444
it('should get tasks from chinook', async () => {
45-
await expect(element(by.text(/get started/i))).toBeVisible();
45+
await waitFor(element(by.text(/get started/i))).toBeVisible().withTimeout(10000);
4646
await element(by.text(/get started/i)).tap();
4747

48-
await expect(element(by.text(/inbox/i))).toBeVisible();
48+
await waitFor(element(by.text(/inbox/i))).toBeVisible().withTimeout(10000);
4949
await element(by.text(/inbox/i)).tap();
5050
await waitFor(element(by.text(/task_work/i))).toBeVisible().withTimeout(10000);
5151
await waitFor(element(by.text(/task_personal/i))).toBeVisible().withTimeout(10000);
5252
await pressBack();
5353

54-
await expect(element(by.text(/work/i))).toBeVisible();
54+
await waitFor(element(by.text(/work/i))).toBeVisible().withTimeout(10000);
5555
await element(by.text(/work/i)).tap();
5656
await waitFor(element(by.text(/task_work/i))).toBeVisible().withTimeout(10000);
5757
await pressBack();
5858

59-
await expect(element(by.text(/personal/i))).toBeVisible();
59+
await waitFor(element(by.text(/personal/i))).toBeVisible().withTimeout(10000);
6060
await element(by.text(/personal/i)).tap();
6161
await waitFor(element(by.text(/task_personal/i))).toBeVisible().withTimeout(10000);
6262
await pressBack();
6363

64-
await expect(element(by.text(/categories/i))).toBeVisible();
64+
await waitFor(element(by.text(/categories/i))).toBeVisible().withTimeout(10000);
6565
});
6666
});

0 commit comments

Comments
 (0)