Test MoblyBinaryHost
public class MoblyBinaryHostTest
extends Object
implements IRemoteTest , IDeviceTest , IBuildReceiver , ITestFilterReceiver , IShardableTest
Obiekt Java.lang.Object | |
↳ | com.android.tradefed.testtype.mobly.MoblyBinaryHostTest |
Test hosta mający na celu uruchomienie pliku binarnego Pythona mobly z systemu Android Build (wkrótce)
Streszczenie
Konstruktorzy publiczni | |
---|---|
MoblyBinaryHostTest () |
Metody publiczne | |
---|---|
void | addAllExcludeFilters ( filters) addAllExcludeFilters ( filters) Dodaje |
void | addAllIncludeFilters ( filters) addAllIncludeFilters ( filters) Dodaje |
void | addExcludeFilter (String filter) Dodaje filtr określający, które testy należy wykluczyć. |
void | addIncludeFilter (String filter) Dodaje filtr określający, które testy należy uwzględnić. |
void | clearExcludeFilters () Usuń wszystkie aktualnie śledzone filtry wykluczeń. |
void | clearIncludeFilters () Usuń wszystkie aktualnie śledzone filtry uwzględniania. |
ITestDevice | getDevice () Oddaj urządzenie do testu. |
getExcludeFilters () Zwraca bieżący | |
getIncludeFilters () Zwraca bieżący | |
final void | run ( TestInformation testInfo, ITestInvocationListener listener) Uruchamia testy i raportuje wyniki słuchaczowi. |
void | setBuild ( IBuildInfo buildInfo) |
void | setDevice ( ITestDevice device) Wstrzyknij testowane urządzenie. |
split (int shardCountHint) Alternatywna wersja metody |
Metody chronione | |
---|---|
String[] | buildCommandLineArray (String filePath, String configPath, tests) buildCommandLineArray (String filePath, String configPath, tests) |
String[] | buildCommandLineArray (String filePath, String configPath) |
filterTests (String[] testListLines, String runName, ITestInvocationListener listener) | |
String | getLogDirAbsolutePath () |
File | getLogDirFile () |
boolean | processYamlTestResults (InputStream inputStream, MoblyYamlResultParser parser, ITestInvocationListener listener, String runName) Analizuje wyniki testów Mobly i sporządza raporty o wynikach. |
void | reportLogs (File logDir, ITestInvocationListener listener) |
void | updateConfigFile (InputStream configInputStream, Writer writer) |
Konstruktorzy publiczni
Test MoblyBinaryHost
public MoblyBinaryHostTest ()
Metody publiczne
addAllExcludeFilters
public void addAllExcludeFilters (filters)
Dodaje ERROR(/Set)
filtrów, z których testy mają zostać wykluczone.
Parametry | |
---|---|
filters |
dodajAllIncludeFilters
public void addAllIncludeFilters (filters)
Dodaje ERROR(/Set)
filtrów, które należy uwzględnić w testach.
Parametry | |
---|---|
filters |
dodajWykluczFiltr
public void addExcludeFilter (String filter)
Dodaje filtr określający, które testy należy wykluczyć.
Parametry | |
---|---|
filter | String |
dodajIncludeFilter
public void addIncludeFilter (String filter)
Dodaje filtr określający, które testy należy uwzględnić.
Parametry | |
---|---|
filter | String |
wyczyśćWykluczFiltry
public void clearExcludeFilters ()
Usuń wszystkie aktualnie śledzone filtry wykluczeń.
wyczyśćIncludeFilters
public void clearIncludeFilters ()
Usuń wszystkie aktualnie śledzone filtry uwzględniania.
pobierz urządzenie
public ITestDevice getDevice ()
Oddaj urządzenie do testu.
Zwroty | |
---|---|
ITestDevice | ITestDevice |
pobierzIncludeFilters
publicgetIncludeFilters ()
Zwraca bieżący ERROR(/Set)
filtrów dołączanych.
Zwroty | |
---|---|
uruchomić
public final void run (TestInformation testInfo, ITestInvocationListener listener)
Uruchamia testy i raportuje wyniki słuchaczowi.
Parametry | |
---|---|
testInfo | TestInformation : Obiekt TestInformation zawierający informacje przydatne do uruchamiania testów. |
listener | ITestInvocationListener : ITestInvocationListener wyników testów |
ustaw urządzenie
public void setDevice (ITestDevice device)
Wstrzyknij testowane urządzenie.
Parametry | |
---|---|
device | ITestDevice : ITestDevice do użycia |
podział
publicsplit (int shardCountHint)
Alternatywna wersja metody split()
, która udostępnia również wartość shardCount, którą próbuje się uruchomić. Jest to przydatne dla niektórych biegaczy testowych, którzy czasami nie mogą arbitralnie decydować.
Parametry | |
---|---|
shardCountHint | int : liczba prób fragmentu. |
Zwroty | |
---|---|
zbiór podtestów, które mają być wykonane osobno lub mają wartość null , jeśli testu nie można obecnie podzielić |
Metody chronione
buildCommandLineArray
protected String[] buildCommandLineArray (String filePath, String configPath,tests)
Parametry | |
---|---|
filePath | String |
configPath | String |
tests |
Zwroty | |
---|---|
String[] |
buildCommandLineArray
protected String[] buildCommandLineArray (String filePath, String configPath)
Parametry | |
---|---|
filePath | String |
configPath | String |
Zwroty | |
---|---|
String[] |
testy filtrów
protectedfilterTests (String[] testListLines, String runName, ITestInvocationListener listener)
Parametry | |
---|---|
testListLines | String |
runName | String |
listener | ITestInvocationListener |
Zwroty | |
---|---|
getLogDirAbsolutePath
protected String getLogDirAbsolutePath ()
Zwroty | |
---|---|
String |
pobierz plik LogDir
protected File getLogDirFile ()
Zwroty | |
---|---|
File |
ProcessYamlTestResults
protected boolean processYamlTestResults (InputStream inputStream, MoblyYamlResultParser parser, ITestInvocationListener listener, String runName)
Analizuje wyniki testów Mobly i sporządza raporty o wynikach.
Parametry | |
---|---|
inputStream | InputStream : Odczyt obiektu WejścieStream w pliku wyników testu Mobly. |
parser | MoblyYamlResultParser : Obiekt MoblyYamlResultParser, który przetwarza wyniki testów Mobly. |
listener | ITestInvocationListener : instancja ITestInvocationListener, która wykonuje różne raporty. |
runName | String : str, nazwa uruchomienia binarnego testu Mobly. |
Zwroty | |
---|---|
boolean |
raportLogi
protected void reportLogs (File logDir, ITestInvocationListener listener)
Parametry | |
---|---|
logDir | File |
listener | ITestInvocationListener |
aktualizacja pliku konfiguracyjnego
protected void updateConfigFile (InputStream configInputStream, Writer writer)
Parametry | |
---|---|
configInputStream | InputStream |
writer | Writer |
Rzuca | |
---|---|
HarnessRuntimeException |