android-test
android-test copied to clipboard
Orchestrator sometimes runs all the instances of a parameterized test in the same process
Description
Orchestrator has a fast path that skips test discovery if the test target is a single method:
https://github.com/android/android-test/blob/dd62f39c79bddbaa3b3c0aad2976ba635a5550ea/runner/android_test_orchestrator/java/androidx/test/orchestrator/AndroidTestOrchestrator.java#L259-L262
This doesn't work for parameterized tests, since even a single method target may expand to any number of parameterized test instances.
Steps to Reproduce
Run a parameterized test method through test orchestrator. They will all run in the same process. You can verify this by logging the PID.
Expected Results
Each instance of the parameterized test runs in its own process.
Actual Results
All of the instances of the parameterized test run in the same process.