Hide Keyboard using APPIUM

Let’s see, How can you Hide Keyboard using Appium during Test. In previous tutorials, You have seen, How to handle TextBox in Android. Now we will see, How can we hide Keyboard in Andriod Application.

 

In Android Device, When you click on any TextBox, It will show you the soft keyboard on the screen. Once you have done it will hide Automatically. Now, suppose you want to perform some action on an element which is hidden behind the android keyboard. For that, You need to hide android keyboard first.

 

Hide Keyboard using Appium

In Appium, It is very easy to hide keyboard using hideKeyboard() method of AndroidDriver.

Now implement the Test. Let’s take an example, Open your Contacts on your mobile device. Click on Add Contact icon. Find the Name field and Type the Contact name and hide the keyboard after entering the text.

 

Let’s understand this using this simple example-

In above example, We have implemented the logic to Hiding Keyboard.

 

Using this way, You can handle the Keyboard in Andriod using Appium.

0 Comment

Leave a Reply