Skip to main content

SeeTestAutomation- ApplicationClearData

info

Please note that this tool is classified as a Legacy tool. We recommend transitioning to our updated solutions to maintain optimal performance and security in your workflows. For more information on this matter, please reach out to technical support .

ApplicationClearData(app)

Description

Android - This command will clear the entire application data and cache from the device it is installed on during runtime.

iOS (supported since 12.2) - This command will clear application's data.

Parameters

  • Package Name**:** The application package name.

Usage

Scenario: On the following example we will use the EriBank Application to demonstrate the use of this command.

Step 1: Go to Settings Tab (Settings->App->All->EriBank).

See the app info. In this example

Step 2: Execute the applicationClearData command.

Step 3: Check the result.

Code Examples

Java Example

client.applicationClearData("com.experitest.ExperiBank/.LoginActivity");

C# Example Expand source

client.ApplicationClearData("com.experitest.ExperiBank/.LoginActivity");

VBScript Example Expand source

client.ApplicationClearData "com.experitest.ExperiBank/.LoginActivity"

Python Example Expand source

self.client.applicationClearData("com.experitest.ExperiBank/.LoginActivity")

Perl Example Expand source

$client->applicationClearData("com.experitest.ExperiBank/.LoginActivity");

Clear iOS Application Data

  • Supported only on applications signed for development

  • Some of the capabilities required instrumentation from 12.2

  • Application's Permissions (such as Camera / Notifications / Location permissions) will not be cleared using clearApplicationData command. Clearing these will require reinstallation or manual management via the Settings app

Will  clear application data of the following types:

  1. Application's Container - All files created by the application

  2. Application's Group Container * - All files created by the application's groups, as listed in its Info.plist (supported only for Instrumented app). 

  3. Application's Defaults - User defaults configured by the application

  4. Application's Settings * - Special type of user defaults that are configured by the developer in the 'Settings.bundle' and stored in the device settings app (supported only for Instrumented app)

  5. Application Group Keychain Items * - Passwords, keys and other types of  data stored in the device keychain (supported only for Instrumented app)

  • Will take affect on the next launch of the application