Alt süreçTfLauncher
public abstract class SubprocessTfLauncher
extends Object
implements IBuildReceiver , IInvocationContextReceiver , IRemoteTest , IConfigurationReceiver
java.lang.Nesne | |
↳ | com.android.tradefed.testtype.SubprocessTfLauncher |
Ayrı bir TF kurulumuna karşı testler çalıştırmak için bir IRemoteTest
.
Testleri çalıştırmak için harici bir Java işlemi başlatır. TF ünitesini veya fonksiyonel testleri sürekli olarak çalıştırmak için kullanılır.
Özet
Alanlar | |
---|---|
public static final String | ANDROID_SERIAL_VAR Çevre |
public static final String | PARENT_PROC_TAG_NAME |
public static final String | SUBPROCESS_TAG_NAME Ayırt etmek için TF alt işlemine iletilecek etiket |
protected IBuildInfo | mBuildInfo |
protected | mCmdArgs |
protected IConfiguration | mConfig |
protected String | mRootDir |
protected IRunUtil | mRunUtil |
protected File | mTmpDir
|
Kamu inşaatçıları | |
---|---|
SubprocessTfLauncher () |
Genel yöntemler | |
---|---|
void | run ( TestInformation testInfo, ITestInvocationListener listener) Testleri çalıştırır ve sonucu dinleyiciye bildirir. |
void | setBuild ( IBuildInfo buildInfo) |
void | setConfiguration ( IConfiguration configuration) Kullanımdaki |
void | setInvocationContext ( IInvocationContext invocationContext) |
Korumalı yöntemler | |
---|---|
void | addJavaArguments ( args) addJavaArguments ( args) Alt süreç çağrısına fazladan Java parametreleri eklemeye izin verin. |
IRunUtil | getRunUtil () Alt işlem komutu için kullanılacak |
void | postRun ( ITestInvocationListener listener, boolean exception, long elapsedTime) TF testi bittikten sonra yapılacak işlemler. |
void | preRun () Testi çalıştırmadan önce kurulum yapın. |
void | setEventStreaming (boolean eventStreaming) Use-event-streaming'i ayarlayın. |
void | setRunUtil ( IRunUtil runUtil) IRunUtil'i ayarlayın. |
Alanlar
ANDROID_SERIAL_VAR
public static final String ANDROID_SERIAL_VAR
Çevre adb seçimini etkileyen değişken.
PARENT_PROC_TAG_NAME
public static final String PARENT_PROC_TAG_NAME
SUBPROCESS_TAG_NAME
public static final String SUBPROCESS_TAG_NAME
Ayırt etmek için TF alt işlemine iletilecek etiket
mBuildInfo
protected IBuildInfo mBuildInfo
mCmdArgs
protectedmCmdArgs
mYapılandırma
protected IConfiguration mConfig
mRootDir
protected String mRootDir
mRunUtil
protected IRunUtil mRunUtil
mTmpDir
protected File mTmpDir
Kamu inşaatçıları
Alt süreçTfLauncher
public SubprocessTfLauncher ()
Genel yöntemler
koşmak
public void run (TestInformation testInfo, ITestInvocationListener listener)
Testleri çalıştırır ve sonucu dinleyiciye bildirir.
parametreler | |
---|---|
testInfo | TestInformation : Testleri çalıştırmak için faydalı bilgiler içeren TestInformation nesnesi. |
listener | ITestInvocationListener : test sonuçlarının ITestInvocationListener |
atar | |
---|---|
DeviceNotAvailableException |
setYapılandırma
public void setConfiguration (IConfiguration configuration)
Kullanımdaki IConfiguration
enjekte eder.
parametreler | |
---|---|
configuration | IConfiguration |
setInvocationContext
public void setInvocationContext (IInvocationContext invocationContext)
parametreler | |
---|---|
invocationContext | IInvocationContext |
Korumalı yöntemler
JavaArgümanları ekle
protected void addJavaArguments (args)
Alt süreç çağrısına fazladan Java parametreleri eklemeye izin verin.
parametreler | |
---|---|
args |
getRunUtil
protected IRunUtil getRunUtil ()
Alt işlem komutu için kullanılacak IRunUtil
döndürür.
İadeler | |
---|---|
IRunUtil |
postRun
protected void postRun (ITestInvocationListener listener, boolean exception, long elapsedTime)
TF testi bittikten sonra yapılacak işlemler.
parametreler | |
---|---|
listener | ITestInvocationListener : sonuçların raporlanacağı orijinal ITestInvocationListener . |
exception | boolean : Testin içinde istisna oluşturulduysa doğrudur. |
elapsedTime | long : testleri çalıştırmak için geçen süre. |
ön çalıştırma
protected void preRun ()
Testi çalıştırmadan önce kurulum yapın.
setEventAkış
protected void setEventStreaming (boolean eventStreaming)
Use-event-streaming'i ayarlayın. Birim testi için açık.
parametreler | |
---|---|
eventStreaming | boolean |
setRunUtil
protected void setRunUtil (IRunUtil runUtil)
IRunUtil'i ayarlayın. Birim testi için açık.
parametreler | |
---|---|
runUtil | IRunUtil |