execute mobile command

Execute a mobile command-line and return its output.
NameDescriptionTypeModifier
command

Command to be executed

StringNone
argument

(Optional) Define an argument using the JSON serializable for the current action definition.

StringNone
variable

(Optional) Variable to receive the command output.

StringNone
The command output when executing a mobile command-line.
This action may be used within the following project items: test modules and user-defined actions.
The following settings are applicable to this action: case sensitive, remove double quotes from cells, standard ASCII only, object wait, window wait.
Suppose you may want to issue two commands in your automation script.
  • One command is to launch an application, such as MapsActivity.
  • The other is to return information relating to the current mobile device.
                                
                                    	command	argument	variable
execute mobile command	mobile: shell	{"command":"am start -n com.google.android.apps.maps/com.google.android.maps.MapsActivity"}	>> ac_output
&nbsp			
	command	variable	
execute mobile command	mobile:deviceInfo	>> ac_output	
                                
                            
  • This built-in action is supported only on Windows test controllers; it is effective on mobile devices test platforms.
  • The execute mobile command action can be invoked to execute any commands that are supported by Appium. (For further details, refer to the Help topic for this action in docs (Note that in Android, when using the mobile:shell command, adb shell requires permission to execute on the device. Additionally, the script must be wrapped with the argument command. For example, to list all packages, the argument would be {'command': 'pm list packages'})). Learn more above.

Copyright © 2024 LogiGear Corporation. All rights reserved. LogiGear is a registered trademark, and Action Based Testing and TestArchitect are trademarks of LogiGear Corporation. All other trademarks contained herein are the property of their respective owners.

LogiGear Corporation

1730 S. Amphlett Blvd. Suite 200, San Mateo, CA 94402

Tel: +1 (650) 572-1400