ParentSandboxInvocationExecution

public class ParentSandboxInvocationExecution
extends InvocationExecution

java.lang.Object
   ↳ com.android.tradefed.invoker.InvocationExecution
     ↳ com.android.tradefed.invoker.sandbox.ParentSandboxInvocationExecution


サンドボックスの実行時に親呼び出しの特別なアクションに使用する InvocationExecution のバージョン。

概要

パブリック コンストラクタ

ParentSandboxInvocationExecution()

パブリック メソッド

void doCleanUp(IInvocationContext context, IConfiguration config, Throwable exception)

target_preparer と multi_target_preparer の cleanUp ステップを実行します。

void doSetup(TestInformation testInfo, IConfiguration config, ITestLogger listener)

target_preparer と multi_target_preparer の setUp ステップを実行します。

void doTeardown(TestInformation testInfo, IConfiguration config, ITestLogger logger, Throwable exception)

target_preparer と multi_target_preparer のティアダウン ステップを実行します。

boolean fetchBuild(TestInformation testInfo, IConfiguration config, IRescheduler rescheduler, ITestInvocationListener listener)

呼び出しの build_provider ステップを実行します。

void reportLogs(ITestDevice device, ITestLogger logger, TestInvocation.Stage stage)

呼び出しのさまざまな段階でデバイスログをレポートします。

void runDevicePostInvocationTearDown(IInvocationContext context, IConfiguration config, Throwable exception)

呼び出しのデバイス部分ごとに ITestDevice.postInvocationTearDown(Throwable) を呼び出します。

void runDevicePreInvocationSetup(IInvocationContext context, IConfiguration config, ITestLogger logger)

呼び出しのデバイス部分ごとに ERROR(ITestDevice.preInvocationSetup(IBuildInfo)/com.android.tradefed.device.ITestDevice#preInvocationSetup(com.android.tradefed.build.IBuildInfo) ITestDevice.preInvocationSetup(IBuildInfo)) を呼び出します。

void runTests(TestInformation info, IConfiguration config, ITestInvocationListener listener)

テストを実行します。

保護されたメソッド

IConfigurationFactory getFactory()

構成の作成に使用される IConfigurationFactory を返します。

List<ITargetPreparer> getLabPreparersToRun(IConfiguration config, String deviceName)

このデバイスで実行するラボの準備担当者のリストを取得します。

IRunUtil getRunUtil()
List<ITargetPreparer> getTargetPreparersToRun(IConfiguration config, String deviceName)

このデバイスで実行するターゲット プリペアラのリストを取得します。

boolean prepareAndRunSandbox(TestInformation info, IConfiguration config, ITestInvocationListener listener)

サンドボックスの実行結果のステータスを返します。

パブリック コンストラクタ

ParentSandboxInvocationExecution

public ParentSandboxInvocationExecution ()

パブリック メソッド

doCleanUp

public void doCleanUp (IInvocationContext context, 
                IConfiguration config, 
                Throwable exception)

target_preparer と multi_target_preparer の cleanUp ステップを実行します。デバイスをクリーンアップします。

パラメータ
context IInvocationContext: 呼び出しの IInvocationContext

config IConfiguration: このテスト実行の IConfiguration

exception Throwable: テスト実行によってスローされた元の例外。

doSetup

public void doSetup (TestInformation testInfo, 
                IConfiguration config, 
                ITestLogger listener)

target_preparer と multi_target_preparer の setUp ステップを実行します。テストの実行に必要なすべてのデバイス設定を行います。

パラメータ
testInfo TestInformation: 呼び出しの TestInformation

config IConfiguration: このテスト実行の IConfiguration

listener ITestLogger: 設定失敗ログを報告する ITestLogger

例外
BuildError
DeviceNotAvailableException
TargetSetupError

doTeardown

public void doTeardown (TestInformation testInfo, 
                IConfiguration config, 
                ITestLogger logger, 
                Throwable exception)

target_preparer と multi_target_preparer のティアダウン ステップを実行します。セットアップに関連付けられているデバイスを分解します。

パラメータ
testInfo TestInformation: 呼び出しの TestInformation

config IConfiguration: このテスト実行の IConfiguration

logger ITestLogger: ログをレポートする ITestLogger

exception Throwable: テスト実行によってスローされた元の例外。

例外
Throwable

fetchBuild

public boolean fetchBuild (TestInformation testInfo, 
                IConfiguration config, 
                IRescheduler rescheduler, 
                ITestInvocationListener listener)

呼び出しの build_provider ステップを実行します。

パラメータ
testInfo TestInformation: 呼び出しの TestInformation

config IConfiguration: このテスト実行の IConfiguration

rescheduler IRescheduler: 別のリソースで実行するために呼び出しの一部を再スケジュールする IRescheduler

listener ITestInvocationListener: ビルドのダウンロードの失敗を報告する ITestInvocation

戻り値
boolean ビルドのダウンロードに成功した場合は true、それ以外の場合は false。

例外
BuildRetrievalError
DeviceNotAvailableException

reportLogs

public void reportLogs (ITestDevice device, 
                ITestLogger logger, 
                TestInvocation.Stage stage)

呼び出しのさまざまな段階でデバイスログをレポートします。例: logcat。

パラメータ
device ITestDevice: ログを報告するデバイス。

logger ITestLogger: ログのロガー。

stage TestInvocation.Stage: 現在の呼び出しのステージ。

runDevicePostInvocationTearDown

public void runDevicePostInvocationTearDown (IInvocationContext context, 
                IConfiguration config, 
                Throwable exception)

呼び出しのデバイス部分ごとに ITestDevice.postInvocationTearDown(Throwable) を呼び出します。

パラメータ
context IInvocationContext: 呼び出しの IInvocationContext

config IConfiguration: このテスト実行の IConfiguration

exception Throwable: テスト実行によってスローされた元の例外(ある場合)。

runDevicePreInvocationSetup

public void runDevicePreInvocationSetup (IInvocationContext context, 
                IConfiguration config, 
                ITestLogger logger)

呼び出しのデバイス部分ごとに ERROR(ITestDevice.preInvocationSetup(IBuildInfo)/com.android.tradefed.device.ITestDevice#preInvocationSetup(com.android.tradefed.build.IBuildInfo) ITestDevice.preInvocationSetup(IBuildInfo)) を呼び出します。

パラメータ
context IInvocationContext: 呼び出しの IInvocationContext

config IConfiguration: このテスト実行の IConfiguration

logger ITestLogger: ログをレポートする ITestLogger

例外
DeviceNotAvailableException
TargetSetupError

runTests

public void runTests (TestInformation info, 
                IConfiguration config, 
                ITestInvocationListener listener)

テストを実行します。

パラメータ
info TestInformation: テストの実行に使用する TestInformation

config IConfiguration: 実行する IConfiguration

listener ITestInvocationListener: テスト結果の ITestInvocationListener

例外
Throwable

保護されたメソッド

getFactory

protected IConfigurationFactory getFactory ()

構成の作成に使用される IConfigurationFactory を返します。

戻り値
IConfigurationFactory

getLabPreparersToRun

protected List<ITargetPreparer> getLabPreparersToRun (IConfiguration config, 
                String deviceName)

このデバイスで実行するラボの準備担当者のリストを取得します。

サンドボックス クラスでオーバーライドされ、サンドボックスの子内でラボの準備ツールが実行されないように制限します

パラメータ
config IConfiguration

deviceName String

戻り値
List<ITargetPreparer>

getRunUtil

protected IRunUtil getRunUtil ()

戻り値
IRunUtil

getTargetPreparersToRun

protected List<ITargetPreparer> getTargetPreparersToRun (IConfiguration config, 
                String deviceName)

このデバイスで実行するターゲット プリペアラのリストを取得します。

サンドボックス クラスでオーバーライドされ、サンドボックスの子内でラボの準備ツールが実行されないように制限します。

パラメータ
config IConfiguration

deviceName String

戻り値
List<ITargetPreparer>

prepareAndRunSandbox

protected boolean prepareAndRunSandbox (TestInformation info, 
                IConfiguration config, 
                ITestInvocationListener listener)

サンドボックスの実行結果のステータスを返します。

パラメータ
info TestInformation

config IConfiguration

listener ITestInvocationListener

戻り値
boolean

例外
Throwable