From 180f7b5510a7055e11ae7c13c7ea54c4d95f7ebb Mon Sep 17 00:00:00 2001 From: Alexander Sorokin Date: Thu, 30 Mar 2017 17:52:15 +0300 Subject: [PATCH] CB-12618: (android) Appium tests: Handle native cling --- appium-tests/android/android.spec.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/appium-tests/android/android.spec.js b/appium-tests/android/android.spec.js index 6b259c30d..34e65b52c 100644 --- a/appium-tests/android/android.spec.js +++ b/appium-tests/android/android.spec.js @@ -610,6 +610,15 @@ describe('Camera tests Android.', function () { .deviceKeyEvent(BACK_BUTTON) .elementById('Apps') .click() + .then(function () { + return driver + .elementByXPath('//android.widget.Button[@text="OK"]') + .click() + .fail(function () { + // no cling is all right + // it is not a brand new emulator, then + }); + }) .elementByAndroidUIAutomator('new UiSelector().text("Gallery")') .click() .elementByAndroidUIAutomator('new UiSelector().textContains("Pictures")')