ชื่อ MangleListener

public abstract class NameMangleListener
extends Object implements ITestInvocationListener

java.lang.Object
com.android.tradefed.result.NameMangleListener


ตัวฟังพร็อกซีเพื่อแปลวิธีทดสอบ คลาส และชื่อแพ็คเกจเมื่อมีการรายงานผลลัพธ์

สรุป

ผู้รับเหมาก่อสร้างสาธารณะ

NameMangleListener (ITestInvocationListener listener)

วิธีการสาธารณะ

TestSummary getSummary ()

void invocationEnded (long elapsedTime)

void invocationFailed (Throwable cause)

void invocationStarted (IInvocationContext context)

void testAssumptionFailure (TestDescription test, String trace)

void testEnded (TestDescription test, testMetrics) testEnded (TestDescription test, testMetrics)

void testFailed (TestDescription test, String trace)

void testIgnored (TestDescription test)

void testLog (String dataName, LogDataType dataType, InputStreamSource dataStream)

void testRunEnded (long elapsedTime, runMetrics) testRunEnded (long elapsedTime, runMetrics)

void testRunFailed (String errorMessage)

void testRunStarted (String runName, int testCount)

void testRunStopped (long elapsedTime)

void testStarted (TestDescription test)

วิธีการที่ได้รับการป้องกัน

TestDescription mangleTestId (TestDescription test)

เมธอดนี้รันบน TestDescription ทั้งหมดที่ส่งผ่านไปยัง testStarted(com.android.tradefed.result.TestDescription) , testFailed(com.android.tradefed.result.TestDescription, String) และ ITestLifeCycleReceiver.testEnded(com.android.tradefed.result.TestDescription, HashMap) โทรกลับ

String mangleTestRunName (String name)

วิธีการนี้รันบนชื่อการทดสอบรันทั้งหมดที่ถูกส่งผ่านไปยังการเรียกกลับ testRunStarted(String, int)

ผู้รับเหมาก่อสร้างสาธารณะ

ชื่อ MangleListener

public NameMangleListener (ITestInvocationListener listener)

พารามิเตอร์
listener ITestInvocationListener

วิธีการสาธารณะ

รับสรุป

public TestSummary getSummary ()

การส่งคืน
TestSummary

การร้องขอสิ้นสุดแล้ว

public void invocationEnded (long elapsedTime)

พารามิเตอร์
elapsedTime long

การร้องขอล้มเหลว

public void invocationFailed (Throwable cause)

พารามิเตอร์
cause Throwable

การร้องขอเริ่มต้นแล้ว

public void invocationStarted (IInvocationContext context)

พารามิเตอร์
context IInvocationContext

ทดสอบความล้มเหลว

public void testAssumptionFailure (TestDescription test, 
                String trace)

พารามิเตอร์
test TestDescription

trace String

การทดสอบสิ้นสุดแล้ว

public void testEnded (TestDescription test, 
                 testMetrics)

พารามิเตอร์
test TestDescription

testMetrics

การทดสอบล้มเหลว

public void testFailed (TestDescription test, 
                String trace)

พารามิเตอร์
test TestDescription

trace String

ทดสอบละเว้น

public void testIgnored (TestDescription test)

พารามิเตอร์
test TestDescription

บันทึกการทดสอบ

public void testLog (String dataName, 
                LogDataType dataType, 
                InputStreamSource dataStream)

พารามิเตอร์
dataName String

dataType LogDataType

dataStream InputStreamSource

ทดสอบรันสิ้นสุดแล้ว

public void testRunEnded (long elapsedTime, 
                 runMetrics)

พารามิเตอร์
elapsedTime long

runMetrics

testRunFailed

public void testRunFailed (String errorMessage)

พารามิเตอร์
errorMessage String

ทดสอบ RunStarted

public void testRunStarted (String runName, 
                int testCount)

พารามิเตอร์
runName String

testCount int

testRunStopped

public void testRunStopped (long elapsedTime)

พารามิเตอร์
elapsedTime long

ทดสอบเริ่มต้นแล้ว

public void testStarted (TestDescription test)

พารามิเตอร์
test TestDescription

วิธีการที่ได้รับการป้องกัน

MangleTestId

protected TestDescription mangleTestId (TestDescription test)

เมธอดนี้รันบน TestDescription ทั้งหมดที่ส่งผ่านไปยัง testStarted(com.android.tradefed.result.TestDescription) , testFailed(com.android.tradefed.result.TestDescription, String) และ ITestLifeCycleReceiver.testEnded(com.android.tradefed.result.TestDescription, HashMap) โทรกลับ วิธีการควรส่งคืน TestDescription ที่แตกต่างกันที่อาจจะถูกส่งผ่านไปยัง ITestInvocationListener ดาวน์สตรีมที่ระบุระหว่างการก่อสร้าง

การใช้งานควรระมัดระวังที่จะไม่แก้ไข TestDescription ดั้งเดิม

การใช้งานเริ่มต้นจะส่งผ่านตัวระบุขาเข้าผ่านทางที่ไม่มีการแก้ไข

พารามิเตอร์
test TestDescription

การส่งคืน
TestDescription

mangleTestRunName

protected String mangleTestRunName (String name)

วิธีการนี้รันบนชื่อการทดสอบรันทั้งหมดที่ถูกส่งผ่านไปยังการเรียกกลับ testRunStarted(String, int) วิธีการควรส่งคืนชื่อรันการทดสอบที่แตกต่างกันที่อาจจะถูกส่งผ่านไปยัง ITestInvocationListener ดาวน์สตรีมที่ระบุระหว่างการก่อสร้าง

การใช้งานควรระมัดระวังที่จะไม่แก้ไขชื่อการรันเดิม

การใช้งานเริ่มต้นจะส่งผ่านชื่อการทดสอบที่เข้ามาผ่านโดยไม่มีการแก้ไข

พารามิเตอร์
name String

การส่งคืน
String