IMultiTargetPreparer
public
interface
IMultiTargetPreparer
implements
IDisableable
com.android.tradefed.targetprep.multi.IMultiTargetPreparer |
|
เตรียมสภาพแวดล้อมการทดสอบสำหรับอุปกรณ์หลายเครื่องพร้อมกัน ใช้สำหรับการตั้งค่าที่ต้องอาศัยอุปกรณ์หลายเครื่องเท่านั้น ไม่เช่นนั้นให้ใช้ ITargetPreparer
ปกติในอุปกรณ์แต่ละเครื่อง
โปรดทราบว่าคุณระบุ IMultiTargetPreparer
หลายรายการได้ในการกำหนดค่า เราขอแนะนำให้ IMultiTargetPreparer แต่ละรายการบันทึกสภาพแวดล้อมที่คาดไว้ก่อนและหลังการตั้งค่าอย่างชัดเจน
สรุป
เมธอดสาธารณะ | |
---|---|
default
void
|
setUp(IInvocationContext context)
เราเลิกใช้งานเมธอดนี้แล้ว
ให้ใช้ |
default
void
|
setUp(TestInformation testInformation)
ตั้งค่าเป้าหมายสําหรับการทดสอบ |
default
void
|
tearDown(TestInformation testInformation, Throwable e)
ทําการล้าง/รื้อถอนเป้าหมายหลังจากการทดสอบ |
default
void
|
tearDown(IInvocationContext context, Throwable e)
เราเลิกใช้งานเมธอดนี้แล้ว
ให้ใช้ |
เมธอดสาธารณะ
setUp
public void setUp (IInvocationContext context)
วิธีการนี้เลิกใช้งานแล้ว
โปรดใช้ setUp(com.android.tradefed.invoker.TestInformation)
แทน
ตั้งค่าเป้าหมายสําหรับการทดสอบ
พารามิเตอร์ | |
---|---|
context |
IInvocationContext : IInvocationContext ที่อธิบายการเรียกใช้ อุปกรณ์ บิลด์ |
การโยน | |
---|---|
TargetSetupError |
if fatal error occurred setting up environment |
BuildError |
ในกรณีที่เกิดข้อผิดพลาดเกี่ยวกับบิลด์ |
DeviceNotAvailableException |
หากอุปกรณ์ไม่ตอบสนอง |
setUp
public void setUp (TestInformation testInformation)
ตั้งค่าเป้าหมายสําหรับการทดสอบ
พารามิเตอร์ | |
---|---|
testInformation |
TestInformation : TestInformation ที่อธิบายการเรียกใช้ อุปกรณ์ และบิลด์ |
การโยน | |
---|---|
TargetSetupError |
if fatal error occurred setting up environment |
BuildError |
ในกรณีที่เกิดข้อผิดพลาดเกี่ยวกับบิลด์ |
DeviceNotAvailableException |
หากอุปกรณ์ไม่ตอบสนอง |
tearDown
public void tearDown (TestInformation testInformation, Throwable e)
ล้าง/รื้อถอนเป้าหมายหลังจากการทดสอบ
พารามิเตอร์ | |
---|---|
testInformation |
TestInformation : TestInformation ที่อธิบายการเรียกใช้ อุปกรณ์ และบิลด์ |
e |
Throwable : หากการเรียกใช้สิ้นสุดด้วยข้อยกเว้น ข้อยกเว้นนี้จะเป็นข้อยกเว้นที่พบในระดับการเรียกใช้ มิเช่นนั้นจะเป็น null |
การโยน | |
---|---|
DeviceNotAvailableException |
หากอุปกรณ์ไม่ตอบสนอง |
tearDown
public void tearDown (IInvocationContext context, Throwable e)
วิธีการนี้เลิกใช้งานแล้ว
โปรดใช้ tearDown(com.android.tradefed.invoker.TestInformation, Throwable)
แทน
ทําการล้างข้อมูล/รื้อถอนเป้าหมายหลังจากการทดสอบ
พารามิเตอร์ | |
---|---|
context |
IInvocationContext : IInvocationContext ที่อธิบายการเรียกใช้ อุปกรณ์ บิลด์ |
e |
Throwable : หากการเรียกใช้สิ้นสุดด้วยข้อยกเว้น ข้อยกเว้นนี้จะเป็นข้อยกเว้นที่พบในระดับการเรียกใช้ มิเช่นนั้นจะเป็น null |
การโยน | |
---|---|
DeviceNotAvailableException |
หากอุปกรณ์ไม่ตอบสนอง |