run_perf_tests.py
def enable_dump_permission(sdk_path, device_id, dest_dir, package_name):
    """Enable the DUMP permission on the specified and installed Android
    app.
    """

    print 'Starting dump permission grant'
    perm_command = [os.path.join(sdk_path, 'platform-tools', 'adb'),
                    '-s', device_id,
                    'shell',
                    'pm', 'grant', package_name,
                    'android.permission.DUMP']
    log_file_path = os.path.join(dest_dir, 'logs', 'enable_dump_perm.log')
    with open(log_file_path, 'w') as log_file:
        try:
            subprocess.call(perm_command,
                            stdout=log_file,
                            stderr=subprocess.STDOUT,
                            shell=False)
        except OSError:
            print 'ERROR executing permission grant.'
Enable the DUMP permission on the specified and installed Android
    app.
    
Enable the DUMP permission on the specified and installed Android
app.
Enable the DUMP permission on the specified and installed Android app .
def enable_dump_permission(sdk_path, device_id, dest_dir, package_name):
    print 'Starting dump permission grant'
    perm_command = [os.path.join(sdk_path, 'platform-tools', 'adb'),
                    '-s', device_id,
                    'shell',
                    'pm', 'grant', package_name,
                    'android.permission.DUMP']
    log_file_path = os.path.join(dest_dir, 'logs', 'enable_dump_perm.log')
    with open(log_file_path, 'w') as log_file:
        try:
            subprocess.call(perm_command,
                            stdout=log_file,
                            stderr=subprocess.STDOUT,
                            shell=False)
        except OSError:
            print 'ERROR executing permission grant.'
def enable_dump_permission ( sdk_path , device_id , dest_dir , package_name ) : print 'Starting dump permission grant' perm_command = [ os . path . join ( sdk_path , 'platform-tools' , 'adb' ) , '-s' , device_id , 'shell' , 'pm' , 'grant' , package_name , 'android.permission.DUMP' ] log_file_path = os . path . join ( dest_dir , 'logs' , 'enable_dump_perm.log' ) with open ( log_file_path , 'w' ) as log_file : try : subprocess . call ( perm_command , stdout = log_file , stderr = subprocess . STDOUT , shell = False ) except OSError : print 'ERROR executing permission grant.'
Enable the DUMP permission on the specified and installed Android
app.
Enable the DUMP permission on the specified and installed Android app .
"""Enable the DUMP permission on the specified and installed Android
    app.
    """
sdk_path
device_id
dest_dir
package_name