DeviceTestRunSeçenekler

public class DeviceTestRunOptions
extends Object

java.lang.Nesne
com.android.tradefed.testtype.junit4.DeviceTestRunOptions


BaseHostJUnit4Test aracılığıyla cihaz testlerini çalıştırmayla ilgili seçenekler için bir oluşturucu sınıfı.

Özet

Kamu inşaatçıları

DeviceTestRunOptions (String packageName)

Genel yöntemler

DeviceTestRunOptions addExtraListener ( ITestLifeCycleReceiver listener)

Çalıştırılmakta olan enstrümantasyona fazladan bir dinleyici ekleyin.

DeviceTestRunOptions addInstrumentationArg (String key, String value)

Enstrümantasyona iletilecek bir argüman ekleyin.

void clearExtraListeners ()
void clearInstrumentationArgs ()

Daha önce addInstrumentationArg(String, String) ile ayarlanmış tüm enstrümantasyon bağımsız değişkenlerini temizleyin.

String getApkFileName ()

Apk kurulumu için apk dosyasının adını döndürür.

ITestDevice getDevice ()
getExtraListeners ()
String[] getInstallArgs ()

Yükleme komutunun ek seçeneklerini döndürür.

getInstrumentationArgs ()
Long getMaxInstrumentationTimeoutMs ()
Long getMaxTimeToOutputMs ()
String getPackageName ()
String getRunner ()
String getTestClassName ()
String getTestMethodName ()
Long getTestTimeoutMs ()
Integer getUserId ()
boolean isForceQueryable ()

Kurulacak apk sorgulanabilir olmalıdır.

boolean isGrantPermission ()

Apk kurulumu için izin verilip verilmeyeceği.

boolean isHiddenApiCheckDisabled ()
boolean isIsolatedStorageDisabled ()
boolean isRestartDisabled ()
boolean isTestApiCheckDisabled ()
boolean isWindowAnimationDisabled ()
DeviceTestRunOptions setApkFileName (String apkFileName)

Apk kurulumu için apk dosyasının adını ayarlar.

DeviceTestRunOptions setCheckResults (boolean checkResults)

Enstrümantasyon çalışmasının sonuçlarının kontrol edilip edilmeyeceğini ayarlar ve herhangi bir arıza oluşmamasını sağlar.

DeviceTestRunOptions setDevice ( ITestDevice device)
DeviceTestRunOptions setDisableHiddenApiCheck (boolean disableHiddenApiCheck)

--no-hidden-api-check'lerinin host tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

DeviceTestRunOptions setDisableIsolatedStorage (boolean disableIsolatedStorage)

--no-izole-storage öğesinin ana bilgisayar tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

DeviceTestRunOptions setDisableRestart (boolean disableRestart)

Ana bilgisayar tarafından kullanılan 'am aracına' --no-restart eklenip eklenmeyeceğini ayarlar.

DeviceTestRunOptions setDisableTestApiCheck (boolean disableTestApiCheck)

--no-test-api-access'in ana bilgisayar tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

DeviceTestRunOptions setDisableWindowAnimation (boolean disableWindowAnimation)

--no-window-animation öğesinin ana bilgisayar tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

DeviceTestRunOptions setForceQueryable (boolean forceQueryable)

Yüklenecek apk sorgulanabilir değilse false olarak ayarlar.

DeviceTestRunOptions setGrantPermission (boolean grantPermission)

Apk kurulumu için izinler verir.

DeviceTestRunOptions setInstallArgs (String... installArgs)

Yükleme komutunun ek seçeneklerini ayarlar.

DeviceTestRunOptions setMaxInstrumentationTimeoutMs (Long maxInstrumentationTimeoutMs)

Tüm enstrümantasyonun çalışması ve tamamlanması gereken maksimum süreyi (milisaniye cinsinden) ayarlar.

DeviceTestRunOptions setMaxTimeToOutputMs (Long maxTimeToOutputMs)

Enstrümantasyonun durdurulmadan önce çıkış vermeyi durdurabileceği maksimum süreyi (milisaniye cinsinden) ayarlar.

DeviceTestRunOptions setRunner (String runner)

Enstrümantasyonu çalıştırmak için kullanılması gereken enstrümantasyon koşucusunu ayarlar.

DeviceTestRunOptions setTestClassName (String testClassName)

Enstrümantasyonun çalıştırması gereken sınıf adını ayarlar.

DeviceTestRunOptions setTestMethodName (String testMethodName)

Enstrümantasyonun çalıştırması gereken yöntem adını ayarlar.

DeviceTestRunOptions setTestTimeoutMs (Long testTimeoutMs)

Bir testin kesintiye uğramadan önce çalışabileceği maksimum süreyi (milisaniye olarak) ayarlar.

DeviceTestRunOptions setUserId (Integer userId)

Enstrümantasyonun çalışması gereken kullanıcı kimliğini ayarlar.

boolean shouldCheckResults ()

Kamu inşaatçıları

DeviceTestRunSeçenekler

public DeviceTestRunOptions (String packageName)

parametreler
packageName String

Genel yöntemler

addExtraListener

public DeviceTestRunOptions addExtraListener (ITestLifeCycleReceiver listener)

Çalıştırılmakta olan enstrümantasyona fazladan bir dinleyici ekleyin.

parametreler
listener ITestLifeCycleReceiver

İadeler
DeviceTestRunOptions

addInstrumentationArg

public DeviceTestRunOptions addInstrumentationArg (String key, 
                String value)

Enstrümantasyona iletilecek bir argüman ekleyin.

parametreler
key String

value String

İadeler
DeviceTestRunOptions

clearEkstra Dinleyiciler

public void clearExtraListeners ()

clearInstrumentationArgs

public void clearInstrumentationArgs ()

Daha önce addInstrumentationArg(String, String) ile ayarlanmış tüm enstrümantasyon bağımsız değişkenlerini temizleyin.

getApkDosyaAdı

public String getApkFileName ()

Apk kurulumu için apk dosyasının adını döndürür.

İadeler
String

getDevice

public ITestDevice getDevice ()

İadeler
ITestDevice

getExtraDinleyiciler

public  getExtraListeners ()

İadeler

getInstallArgs

public String[] getInstallArgs ()

Yükleme komutunun ek seçeneklerini döndürür.

İadeler
String[]

getInstrumentationArgs

public  getInstrumentationArgs ()

İadeler

getMaxInstrumentationTimeoutMs

public Long getMaxInstrumentationTimeoutMs ()

İadeler
Long

getMaxTimeToOutputMs

public Long getMaxTimeToOutputMs ()

İadeler
Long

getPackageName

public String getPackageName ()

İadeler
String

getRunner

public String getRunner ()

İadeler
String

getTestClassName

public String getTestClassName ()

İadeler
String

getTestMethodName

public String getTestMethodName ()

İadeler
String

getTestTimeoutMs

public Long getTestTimeoutMs ()

İadeler
Long

getUserId

public Integer getUserId ()

İadeler
Integer

isForceQueryable

public boolean isForceQueryable ()

Kurulacak apk sorgulanabilir olmalıdır. Varsayılan değer doğrudur.

İadeler
boolean

isGrantPermission

public boolean isGrantPermission ()

Apk kurulumu için izin verilip verilmeyeceği.

İadeler
boolean

isHiddenApiCheckDevre Dışı

public boolean isHiddenApiCheckDisabled ()

İadeler
boolean

isIsolatedDepolama Devre Dışı

public boolean isIsolatedStorageDisabled ()

İadeler
boolean

isRestartDisabled

public boolean isRestartDisabled ()

İadeler
boolean

isTestApiCheckDevre Dışı

public boolean isTestApiCheckDisabled ()

İadeler
boolean

isWindowAnimationDevre Dışı

public boolean isWindowAnimationDisabled ()

İadeler
boolean

setApkDosyaAdı

public DeviceTestRunOptions setApkFileName (String apkFileName)

Apk kurulumu için apk dosyasının adını ayarlar.

parametreler
apkFileName String

İadeler
DeviceTestRunOptions

setCheckResults

public DeviceTestRunOptions setCheckResults (boolean checkResults)

Enstrümantasyon çalışmasının sonuçlarının kontrol edilip edilmeyeceğini ayarlar ve herhangi bir arıza oluşmamasını sağlar.

parametreler
checkResults boolean

İadeler
DeviceTestRunOptions

setCihaz

public DeviceTestRunOptions setDevice (ITestDevice device)

parametreler
device ITestDevice

İadeler
DeviceTestRunOptions

setDisableHiddenApiCheck

public DeviceTestRunOptions setDisableHiddenApiCheck (boolean disableHiddenApiCheck)

--no-hidden-api-check'lerinin host tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

parametreler
disableHiddenApiCheck boolean

İadeler
DeviceTestRunOptions

setDisableIsolatedDepolama

public DeviceTestRunOptions setDisableIsolatedStorage (boolean disableIsolatedStorage)

--no-izole-storage öğesinin ana bilgisayar tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

parametreler
disableIsolatedStorage boolean

İadeler
DeviceTestRunOptions

setDisableRestart

public DeviceTestRunOptions setDisableRestart (boolean disableRestart)

Ana bilgisayar tarafından kullanılan 'am aracına' --no-restart eklenip eklenmeyeceğini ayarlar.

parametreler
disableRestart boolean

İadeler
DeviceTestRunOptions

setDisableTestApiCheck

public DeviceTestRunOptions setDisableTestApiCheck (boolean disableTestApiCheck)

--no-test-api-access'in ana bilgisayar tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

parametreler
disableTestApiCheck boolean

İadeler
DeviceTestRunOptions

setDisableWindowAnimasyon

public DeviceTestRunOptions setDisableWindowAnimation (boolean disableWindowAnimation)

--no-window-animation öğesinin ana bilgisayar tarafından kullanılan 'am aracına' eklenip eklenmeyeceğini ayarlar.

parametreler
disableWindowAnimation boolean

İadeler
DeviceTestRunOptions

setForceQueryable

public DeviceTestRunOptions setForceQueryable (boolean forceQueryable)

Yüklenecek apk sorgulanabilir değilse false olarak ayarlar.

parametreler
forceQueryable boolean

İadeler
DeviceTestRunOptions

setGrantPermission

public DeviceTestRunOptions setGrantPermission (boolean grantPermission)

Apk kurulumu için izinler verir.

parametreler
grantPermission boolean

İadeler
DeviceTestRunOptions

setInstallArgs

public DeviceTestRunOptions setInstallArgs (String... installArgs)

Yükleme komutunun ek seçeneklerini ayarlar.

parametreler
installArgs String

İadeler
DeviceTestRunOptions

setMaxInstrumentationTimeoutMs

public DeviceTestRunOptions setMaxInstrumentationTimeoutMs (Long maxInstrumentationTimeoutMs)

Tüm enstrümantasyonun çalışması ve tamamlanması gereken maksimum süreyi (milisaniye cinsinden) ayarlar. Zaman aşımı olmaması için 0'a ayarlayın. İsteğe bağlı.

parametreler
maxInstrumentationTimeoutMs Long

İadeler
DeviceTestRunOptions

setMaxTimeToOutputMs

public DeviceTestRunOptions setMaxTimeToOutputMs (Long maxTimeToOutputMs)

Enstrümantasyonun durdurulmadan önce çıkış vermeyi durdurabileceği maksimum süreyi (milisaniye cinsinden) ayarlar. Zaman aşımı olmaması için 0'a ayarlayın. İsteğe bağlı.

parametreler
maxTimeToOutputMs Long

İadeler
DeviceTestRunOptions

setRunner

public DeviceTestRunOptions setRunner (String runner)

Enstrümantasyonu çalıştırmak için kullanılması gereken enstrümantasyon koşucusunu ayarlar. Varsayılan koşucu 'android.support.test.runner.AndroidJUnitRunner'dır. İsteğe bağlı.

parametreler
runner String

İadeler
DeviceTestRunOptions

setTestClassName

public DeviceTestRunOptions setTestClassName (String testClassName)

Enstrümantasyonun çalıştırması gereken sınıf adını ayarlar. Enstrümantasyon yalnızca sınıfı çalıştırmak için filtrelenecektir. setTestMethodName(String) ile kullanılabilir. İsteğe bağlı.

parametreler
testClassName String

İadeler
DeviceTestRunOptions

setTestMethodName

public DeviceTestRunOptions setTestMethodName (String testMethodName)

Enstrümantasyonun çalıştırması gereken yöntem adını ayarlar. Düzgün çalışması için setTestClassName(String) ayarlanmasını gerektirir. İsteğe bağlı.

parametreler
testMethodName String

İadeler
DeviceTestRunOptions

setTestTimeoutMs

public DeviceTestRunOptions setTestTimeoutMs (Long testTimeoutMs)

Bir testin kesintiye uğramadan önce çalışabileceği maksimum süreyi (milisaniye olarak) ayarlar. Zaman aşımı olmaması için 0'a ayarlayın. İsteğe bağlı.

parametreler
testTimeoutMs Long

İadeler
DeviceTestRunOptions

setUserId

public DeviceTestRunOptions setUserId (Integer userId)

Enstrümantasyonun çalışması gereken kullanıcı kimliğini ayarlar. İsteğe bağlı.

parametreler
userId Integer

İadeler
DeviceTestRunOptions

ShouldCheckResults

public boolean shouldCheckResults ()

İadeler
boolean