サブプロセス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 サブプロセスを区別するために 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)

使用中のIConfigurationを挿入します。

void setInvocationContext ( IInvocationContext invocationContext)

保護されたメソッド

void addJavaArguments ( args) addJavaArguments ( args)

サブプロセス呼び出しに追加の Java パラメーターを追加できるようにします。

String getJava ()
IRunUtil getRunUtil ()

サブプロセス コマンドに使用されるIRunUtilを返します。

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 サブプロセスを区別するために TF サブプロセスに渡されるタグ

mBuildInfo

protected IBuildInfo mBuildInfo

mCmdArgs

protected  mCmdArgs

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

setBuild

public void setBuild (IBuildInfo buildInfo)

パラメーター
buildInfo IBuildInfo

set構成

public void setConfiguration (IConfiguration configuration)

使用中のIConfigurationを挿入します。

パラメーター
configuration IConfiguration

setInvocationContext

public void setInvocationContext (IInvocationContext invocationContext)

パラメーター
invocationContext IInvocationContext

保護されたメソッド

addJavaArguments

protected void addJavaArguments ( args)

サブプロセス呼び出しに追加の Java パラメーターを追加できるようにします。

パラメーター
args : 追加の引数を追加する必要がある引数の現在のリスト。

getJava

protected String getJava ()

戻り値
String

getRunUtil

protected IRunUtil getRunUtil ()

サブプロセス コマンドに使用されるIRunUtilを返します。

戻り値
IRunUtil

実行後

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

setProtoReporting

protected void setProtoReporting (boolean protoReporting)

パラメーター
protoReporting boolean

setRunUtil

protected void setRunUtil (IRunUtil runUtil)

IRunUtil を設定します。単体テストのために公開されます。

パラメーター
runUtil IRunUtil