RunOnWorkProfileTargetPreparer

public class RunOnWorkProfileTargetPreparer
extends ProfileTargetPreparer

java.lang.Object
   ↳ com.android.tradefed.targetprep.BaseTargetPreparer
     ↳ com.android.tradefed.targetprep.ProfileTargetPreparer
       ↳ com.android.tradefed.targetprep.RunOnWorkProfileTargetPreparer


An ITargetPreparer that creates a work profile in setup, and marks that tests should be run in that user.

In teardown, the work profile is removed.

If a work profile already exists, it will be used rather than creating a new one, and it will not be removed in teardown.

If the device does not have the managed_users feature, or does not have capacity to create a new user when one is required, then the instrumentation argument skip-tests-reason will be set, and the user will not be changed. Tests running on the device can read this argument to respond to this state.

Summary

Public constructors

RunOnWorkProfileTargetPreparer()

Public constructors

RunOnWorkProfileTargetPreparer

public RunOnWorkProfileTargetPreparer ()