com.android.tradefed.device.metric

Annotations

MetricOption Annotation for test methods annotated with @Test, or if the annotation is part of the annotation list of TestDescription that allows to specify some extra parameters useful for: Tuning the behavior of the collectors, filtering some methods. 

Interfaces

IMetricCollector This interface will be added as a decorator when reporting tests results in order to collect matching metrics. 
IMetricCollectorReceiver Interface for IRemoteTests to implement if they need to get the list of IMetricCollectors for the test run. 

Classes

AtraceCollector A IMetricCollector that runs atrace during a test and collects the result and log them to the invocation. 
AtraceRunMetricCollector Collects the traces from all the test directory under the given directory from the test device, log the test directory and post process the trace files under the test directory and aggregate the metrics. 
BaseDeviceMetricCollector Base implementation of IMetricCollector that allows to start and stop collection on onTestRunStart(com.android.tradefed.device.metric.DeviceMetricData) and ERROR(/#onTestRunEnd(com.android.tradefed.device.metric.DeviceMetricData,Map))
BluetoothConnectionLatencyCollector The collector will push a pre-defined statsd duration metric config to devices and collect Bluetooth connection duration for each profile. 
BluetoothConnectionStateCollector This collector will collect BluetoothConnectionStateChanged metrics and record connection state number for each profile. 
BluetoothHciSnoopLogCollector Collector to enable Bluetooth HCI snoop logging on the DUT and to collect the log for each test. 
BugreportzOnFailureCollector Collect a bugreportz when a test case fails. 
BugreportzOnTestCaseFailureCollector Collect a bugreportz when a test case in a run fails. 
ClangCodeCoverageCollector A BaseDeviceMetricCollector that will pull Clang coverage measurements off of the device and log them as test artifacts. 
CollectorHelper Helper to do some IMetricCollector operations needed in several places. 
CountTestCasesCollector Count and report the number of test cases for a given IRemoteTest
DebugHostLogOnFailureCollector Collector that will gather and log the host-side logs when a test case failure occurs. 
DeviceMetricData Object to hold all the data collected by metric collectors. 
DeviceTraceCollector Collector that will start perfetto trace when a test run starts and log trace file at the end. 
EmulatorMemoryCpuCapturer  
FilePullerDeviceMetricCollector A BaseDeviceMetricCollector that listen for metrics key coming from the device and pull them as a file from the device. 
FilePullerLogCollector Logger of the file reported by the device-side. 
GcovCodeCoverageCollector A BaseDeviceMetricCollector that will pull gcov coverage measurements off of the device and log them as test artifacts. 
GcovKernelCodeCoverageCollector A BaseDeviceMetricCollector that will pull gcov kernel coverage measurements out of debugfs and off of the device and then finally logs them as test artifacts. 
HostStatsdMetricCollector A IMetricCollector that collects statsd metrics from host side using statsd utility commands. 
JavaCodeCoverageCollector A BaseDeviceMetricCollector that will pull Java coverage measurements off of the device and log them as test artifacts. 
LogcatOnFailureCollector Collector that will capture and log a logcat when a test case fails. 
LogcatTimingMetricCollector A metric collector that collects timing information (e.g. user switch time) from logcat during one or multiple repeated tests by using given regex patterns to parse start and end signals of an event from logcat lines. 
ModuleLogcatCollector Version of logcat collector but for module. 
PerfettoPullerMetricCollector Base implementation of FilePullerDeviceMetricCollector that allows pulling the perfetto files from the device and collect the metrics from it. 
RebootReasonCollector Collector that collects device reboot during the test run and report them by reason and counts. 
RuntimeRestartCollector Collector that collects timestamps of runtime restarts (system server crashes) during the test run, if any. 
ScreenshotOnFailureCollector Collector that will capture and log a screenshot when a test case fails. 
ShowmapPullerMetricCollector Base implementation of FilePullerDeviceMetricCollector that allows pulling the showmap files from the device and collect the metrics from it. 
TraceCmdCollector A IMetricCollector that collects traces during the test using trace-cmd, and logs them to the invocation. 

Enums

AutoLogCollector Enumeration describing which collector can automatically be handled by the harness. 
PerfettoPullerMetricCollector.METRIC_FILE_FORMAT