EnableTestTracingRule

public class EnableTestTracingRule
extends LoggingBaseRule

java.lang.Object
   ↳ org.junit.rules.ExternalResource
     ↳ android.support.test.rule.logging.LoggingBaseRule
       ↳ android.support.test.rule.logging.EnableTestTracingRule


When applied to a test class this TestRule calls Trace.beginSection() before test method execution. The TestRule then calls Trace.endSection() after test method execution. The TestRule enables Systrace/Atrace output to have discrete information about when/which test methods were run (which helps during performance test debugging).

If the API level is less than 18 (Jelly Bean) this rule will do nothing since Trace isn't supported.

Usage: \@Rule public EnableTestTracingRule mEnableTestTracing = new EnableTestTracingRule();

Summary

Public constructors

EnableTestTracingRule()

Public methods

void afterTest()
void beforeTest()

Inherited methods

From class android.support.test.rule.logging.LoggingBaseRule
From class org.junit.rules.ExternalResource
From class java.lang.Object
From interface org.junit.rules.TestRule

Public constructors

EnableTestTracingRule

EnableTestTracingRule ()

Public methods

afterTest

void afterTest ()

beforeTest

void beforeTest ()