DeviceJUnit4ClassRunner
public class DeviceJUnit4ClassRunner
extends BlockJUnit4ClassRunner
implements IAbiReceiver , ISetOptionReceiver , ITestInformationReceiver
java.lang.Object |
↳ | org.junit.runner.Runner |
| ↳ | org.junit.runners.ParentRunner<org.junit.runners.model.FrameworkMethod> |
| | ↳ | org.junit.runners.BlockJUnit4ClassRunner |
| | | ↳ | com.android.tradefed.testtype.DeviceJUnit4ClassRunner |
นักวิ่งทดสอบ JUnit4 ที่รองรับ IDeviceTest
ควรระบุเหนือการทดสอบ JUnit4 ด้วยคำอธิบายประกอบ RunWith
สรุป
คลาสที่ซ้อนกัน |
---|
class | DeviceJUnit4ClassRunner.LogAnnotation คำอธิบายประกอบปลอมหมายถึงการส่งบันทึกไปยังนักข่าว |
class | DeviceJUnit4ClassRunner.MetricAnnotation คำอธิบายประกอบปลอมหมายถึงการนำเมตริกไปให้นักข่าว |
class | DeviceJUnit4ClassRunner.TestLogData การดำเนินการของ ExternalResource และ TestRule |
class | DeviceJUnit4ClassRunner.TestMetrics การดำเนินการของ ExternalResource และ TestRule |
ผู้สร้างสาธารณะ
DeviceJUnit4ClassRunner
public DeviceJUnit4ClassRunner (Class<?> klass)
วิธีการสาธารณะ
รับเอบี
public IAbi getAbi ()
วิ่ง
public void run (RunNotifier notifier)
พารามิเตอร์ |
---|
notifier | RunNotifier |
เซทเอบี
public void setAbi (IAbi abi)
public void setTestInformation (TestInformation testInformation)
พารามิเตอร์ |
---|
testInformation | TestInformation |
วิธีการป้องกัน
สร้างการทดสอบ
protected Object createTest ()
เราลบล้าง createTest เพื่อตั้งค่าอุปกรณ์
เรียกใช้เด็ก
protected void runChild (FrameworkMethod method,
RunNotifier notifier)
พารามิเตอร์ |
---|
method | FrameworkMethod |
notifier | RunNotifier |
กับ AfterClasses
protected Statement withAfterClasses (Statement statement)
พารามิเตอร์ |
---|
statement | Statement |
กับก่อนเรียน
protected Statement withBeforeClasses (Statement statement)
พารามิเตอร์ |
---|
statement | Statement |
ตัวอย่างเนื้อหาและโค้ดในหน้าเว็บนี้ขึ้นอยู่กับใบอนุญาตที่อธิบายไว้ในใบอนุญาตการใช้เนื้อหา Java และ OpenJDK เป็นเครื่องหมายการค้าหรือเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2023-04-28 UTC
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"ไม่มีข้อมูลที่ฉันต้องการ"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"ซับซ้อนเกินไป/มีหลายขั้นตอนมากเกินไป"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"ล้าสมัย"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"ปัญหาเกี่ยวกับการแปล"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"ตัวอย่าง/ปัญหาเกี่ยวกับโค้ด"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"อื่นๆ"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"เข้าใจง่าย"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"แก้ปัญหาของฉันได้"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"อื่นๆ"
}]