|
@@ -34,12 +34,9 @@ describe('top level api', () => {
|
34
|
34
|
it('unmount is called on pop', async () => {
|
35
|
35
|
await elementByLabel('Push Lifecycle Screen').tap();
|
36
|
36
|
await expect(elementByLabel('didAppear')).toBeVisible();
|
37
|
|
- try {
|
38
|
|
- await element(by.trait(['button']).and(by.label('Back'))).tap();
|
39
|
|
- } catch (err) {
|
40
|
|
- await element(by.type('_UIModernBarButton').and(by.label('Back'))).tap();
|
41
|
|
- }
|
|
37
|
+ await Utils.tapBackIos();
|
42
|
38
|
await expect(elementByLabel('didDisappear')).toBeVisible();
|
|
39
|
+ await element(by.traits(['button']).and(by.label('OK'))).atIndex(0).tap();
|
43
|
40
|
await expect(elementByLabel('componentWillUnmount')).toBeVisible();
|
44
|
41
|
});
|
45
|
42
|
});
|