ShardListener
public class ShardListener
extends CollectingTestListener
implements ISupportGranularResults
ITestInvocationListener
ที่รวบรวมผลลัพธ์จากส่วนแบ่งการร้องขอ (หรือที่เรียกว่าการแยกการร้องขอเพื่อรันบนทรัพยากรหลายรายการพร้อมกัน) และส่งต่อไปยัง Listener อื่น
สรุป
วิธีการสาธารณะ |
---|
void | invocationEnded (long elapsedTime) |
void | invocationFailed (FailureDescription failure) |
void | invocationFailed (Throwable cause) |
void | invocationStarted (IInvocationContext context) |
void | setSupportGranularResults (boolean enableGranularResults) |
boolean | supportGranularResults () |
void | testLog (String dataName, LogDataType dataType, InputStreamSource dataStream) |
void | testLogSaved (String dataName, LogDataType dataType, InputStreamSource dataStream, LogFile logFile) |
void | testModuleEnded () |
void | testModuleStarted (IInvocationContext moduleContext) |
void | testRunEnded (long elapsedTime, runMetrics) testRunEnded (long elapsedTime, runMetrics) |
void | testRunFailed (FailureDescription failure) |
void | testRunFailed (String failureMessage) |
void | testRunStarted (String name, int numTests, int attemptNumber, long startTime) |
ผู้รับเหมาก่อสร้างสาธารณะ
ShardListener
public ShardListener (ITestInvocationListener main)
สร้าง ShardListener
พารามิเตอร์ |
---|
main | ITestInvocationListener : ITestInvocationListener ควรส่งต่อผลลัพธ์ เพื่อป้องกันการชนกับ ShardListener อื่น ๆ วัตถุนี้จะซิงโครไนซ์บน main เมื่อส่งต่อผลลัพธ์ และผลลัพธ์จะถูกส่งเมื่อชาร์ดการร้องขอเสร็จสมบูรณ์เท่านั้น |
วิธีการสาธารณะ
การร้องขอสิ้นสุดแล้ว
public void invocationEnded (long elapsedTime)
พารามิเตอร์ |
---|
elapsedTime | long |
การร้องขอล้มเหลว
public void invocationFailed (FailureDescription failure)
พารามิเตอร์ |
---|
failure | FailureDescription |
การร้องขอล้มเหลว
public void invocationFailed (Throwable cause)
พารามิเตอร์ |
---|
cause | Throwable |
การร้องขอเริ่มต้นแล้ว
public void invocationStarted (IInvocationContext context)
พารามิเตอร์ |
---|
context | IInvocationContext |
setSupportGranularResults
public void setSupportGranularResults (boolean enableGranularResults)
พารามิเตอร์ |
---|
enableGranularResults | boolean |
สนับสนุนผลลัพธ์แบบละเอียด
public boolean supportGranularResults ()
public void testLog (String dataName,
LogDataType dataType,
InputStreamSource dataStream)
พารามิเตอร์ |
---|
dataName | String |
dataType | LogDataType |
dataStream | InputStreamSource |
public void testLogSaved (String dataName,
LogDataType dataType,
InputStreamSource dataStream,
LogFile logFile)
พารามิเตอร์ |
---|
dataName | String |
dataType | LogDataType |
dataStream | InputStreamSource |
logFile | LogFile |
ทดสอบโมดูลสิ้นสุดแล้ว
public void testModuleEnded ()
ทดสอบโมดูลเริ่มต้นแล้ว
public void testModuleStarted (IInvocationContext moduleContext)
พารามิเตอร์ |
---|
moduleContext | IInvocationContext |
ทดสอบรันสิ้นสุดแล้ว
public void testRunEnded (long elapsedTime,
runMetrics)
พารามิเตอร์ |
---|
elapsedTime | long |
runMetrics | |
testRunFailed
public void testRunFailed (FailureDescription failure)
พารามิเตอร์ |
---|
failure | FailureDescription |
testRunFailed
public void testRunFailed (String failureMessage)
พารามิเตอร์ |
---|
failureMessage | String |
ทดสอบ RunStarted
public void testRunStarted (String name,
int numTests,
int attemptNumber,
long startTime)
พารามิเตอร์ |
---|
name | String |
numTests | int |
attemptNumber | int |
startTime | long |