하위 프로세스TfLauncher
public abstract class SubprocessTfLauncher
extends Object
implements IBuildReceiver , IInvocationContextReceiver , IRemoteTest , IConfigurationReceiver
java.lang.객체 | |
↳ | com.android.tradefed.testtype.SubprocessTfLauncher |
별도의 TF 설치에 대해 테스트를 실행하기 위한 IRemoteTest
입니다.
테스트를 실행하기 위해 외부 Java 프로세스를 시작합니다. TF 단위 또는 기능 테스트를 지속적으로 실행하는 데 사용됩니다.
요약
필드 | |
---|---|
public static final String | ANDROID_SERIAL_VAR 환경 |
public static final String | PARENT_PROC_TAG_NAME |
public static final String | SUBPROCESS_TAG_NAME 구분을 위해 TF 하위 프로세스에 전달될 태그 |
protected IBuildInfo | mBuildInfo |
protected | mCmdArgs |
protected IConfiguration | mConfig |
protected String | mRootDir |
protected IRunUtil | mRunUtil |
protected File | mTmpDir
|
공개 생성자 | |
---|---|
SubprocessTfLauncher () |
공개 방법 | |
---|---|
void | run ( TestInformation testInfo, ITestInvocationListener listener) 테스트를 실행하고 결과를 수신기에 보고합니다. |
void | setBuild ( IBuildInfo buildInfo) |
void | setConfiguration ( IConfiguration configuration) 사용 중인 |
void | setInvocationContext ( IInvocationContext invocationContext) |
보호된 메서드 | |
---|---|
void | addJavaArguments ( args) addJavaArguments ( args) 하위 프로세스 호출에 추가 Java 매개변수를 추가할 수 있습니다. |
String | getJava () |
IRunUtil | getRunUtil () 하위 프로세스 명령에 사용될 |
void | postRun ( ITestInvocationListener listener, boolean exception, long elapsedTime) TF 테스트가 끝난 후 취해야 할 조치. |
void | preRun () 테스트를 실행하기 전에 설정하십시오. |
void | setEventStreaming (boolean eventStreaming) use-event-streaming을 설정합니다. |
void | setProtoReporting (boolean protoReporting) |
void | setRunUtil ( IRunUtil runUtil) IRunUtil을 설정합니다. |
필드
ANDROID_SERIAL_VAR
public static final String ANDROID_SERIAL_VAR
환경 adb 선택에 영향을 미치는 변수.
PARENT_PROC_TAG_NAME
public static final String PARENT_PROC_TAG_NAME
SUBPROCESS_TAG_NAME
public static final String SUBPROCESS_TAG_NAME
구분을 위해 TF 하위 프로세스에 전달될 태그
mBuildInfo
protected IBuildInfo mBuildInfo
mCmdArgs
protectedmCmdArgs
mConfig
protected IConfiguration mConfig
mRootDir
protected String mRootDir
mRunUtil
protected IRunUtil mRunUtil
mTmpDir
protected File mTmpDir
공개 생성자
하위 프로세스TfLauncher
public SubprocessTfLauncher ()
공개 방법
달리다
public void run (TestInformation testInfo, ITestInvocationListener listener)
테스트를 실행하고 결과를 수신기에 보고합니다.
매개변수 | |
---|---|
testInfo | TestInformation : 테스트를 실행하는 데 유용한 정보가 포함된 TestInformation 개체입니다. |
listener | ITestInvocationListener : 테스트 결과의 ITestInvocationListener |
던지기 | |
---|---|
DeviceNotAvailableException |
setConfiguration
public void setConfiguration (IConfiguration configuration)
사용 중인 IConfiguration
주입합니다.
매개변수 | |
---|---|
configuration | IConfiguration |
setInvocationContext
public void setInvocationContext (IInvocationContext invocationContext)
매개변수 | |
---|---|
invocationContext | IInvocationContext |
보호된 메서드
addJava인수
protected void addJavaArguments (args)
하위 프로세스 호출에 추가 Java 매개변수를 추가할 수 있습니다.
매개변수 | |
---|---|
args |
getJava
protected String getJava ()
보고 | |
---|---|
String |
실행 후
protected void postRun (ITestInvocationListener listener, boolean exception, long elapsedTime)
TF 테스트가 끝난 후 취해야 할 조치.
매개변수 | |
---|---|
listener | ITestInvocationListener : 결과를 보고할 원래 ITestInvocationListener 입니다. |
exception | boolean : 테스트 내에서 예외가 발생한 경우 True입니다. |
elapsedTime | long : 테스트를 실행하는 데 걸린 시간. |
사전 실행
protected void preRun ()
테스트를 실행하기 전에 설정하십시오.
setEventStreaming
protected void setEventStreaming (boolean eventStreaming)
use-event-streaming을 설정합니다. 단위 테스트를 위해 노출되었습니다.
매개변수 | |
---|---|
eventStreaming | boolean |
setProto보고
protected void setProtoReporting (boolean protoReporting)
매개변수 | |
---|---|
protoReporting | boolean |
setRunUtil
protected void setRunUtil (IRunUtil runUtil)
IRunUtil을 설정합니다. 단위 테스트를 위해 노출되었습니다.
매개변수 | |
---|---|
runUtil | IRunUtil |