GTestListTestParser

public class GTestListTestParser
extends MultiLineReceiver

java.lang.Object
   ↳ com.android.ddmlib.MultiLineReceiver
     ↳ com.android.tradefed.testtype.GTestListTestParser


gtest 模擬測試模式的結果剖析器,附有「--gtest_list_tests」參數。

摘要

欄位

protected mTests

公用建構函式

GTestListTestParser(String testRunName, ITestInvocationListener listener)

為單一接聽程式建立 GTestListTestParser。

GTestListTestParser(String testRunName, ITestInvocationListener listener, boolean shouldCollectDisabledTest)

為單一接聽程式建立 GTestListTestParser。

公用方法

void done()

終止程序。

boolean getPrependFileName()
boolean isCancelled()

void processNewLines(String[] lines)

當遠端程序收到新行時呼叫。

void setPrependFileName(boolean prepend)

欄位

mTests

protected  mTests

公用建構函式

GTestListTestParser

public GTestListTestParser (String testRunName, 
                ITestInvocationListener listener)

為單一接聽程式建立 GTestListTestParser。

參數
testRunName String:要提供給 ITestLifeCycleReceiver.testRunStarted(String, int) 的測試執行名稱

listener ITestInvocationListener:在測試執行期間收到測試結果通知

GTestListTestParser

public GTestListTestParser (String testRunName, 
                ITestInvocationListener listener, 
                boolean shouldCollectDisabledTest)

為單一接聽程式建立 GTestListTestParser。

參數
testRunName String:要提供給 ITestLifeCycleReceiver.testRunStarted(String, int) 的測試執行名稱

listener ITestInvocationListener:在測試執行期間收到測試結果通知

shouldCollectDisabledTest boolean:是否收集已停用的測試

公用方法

done

public void done ()

終止程序。最後幾行經過 processNewLines(String[]) 後,就會呼叫這個方法。

getPrependFileName

public boolean getPrependFileName ()

傳回
boolean

isCancelled

public boolean isCancelled ()

傳回
boolean

processNewLines

public void processNewLines (String[] lines)

當遠端程序收到新行時呼叫。

系統保證提供給這個方法時,這些行是完整的。

參數
lines String:包含新行的陣列。

setPrependFileName

public void setPrependFileName (boolean prepend)

參數
prepend boolean