| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
package android.os; |
| 18 |
|
| 19 |
import android.perftests.utils.BenchmarkState; |
| 20 |
import android.perftests.utils.PerfStatusReporter; |
| 21 |
|
| 22 |
import androidx.test.filters.LargeTest; |
| 23 |
import androidx.test.runner.AndroidJUnit4; |
| 24 |
|
| 25 |
import org.junit.Rule; |
| 26 |
import org.junit.Test; |
| 27 |
import org.junit.runner.RunWith; |
| 28 |
|
| 29 |
@RunWith(AndroidJUnit4.class) |
| 30 |
@LargeTest |
| 31 |
public class PssPerfTest { |
| 32 |
@Rule |
| 33 |
public PerfStatusReporter mPerfStatusReporter = new PerfStatusReporter(); |
| 34 |
|
| 35 |
@Test |
| 36 |
public void testPss() { |
| 37 |
final BenchmarkState state = mPerfStatusReporter.getBenchmarkState(); |
| 38 |
while (state.keepRunning()) { |
| 39 |
Debug.getPss(); |
| 40 |
} |
| 41 |
} |
| 42 |
} |