Test DPC is an app designed to help EMMs, ISVs, and OEMs to test their applications and platforms in a Android enterprise managed profile (i.e. work profile). It serves as both a sample Device Policy Controller and a testing application to flex the APIs available for Android enterprise. It supports devices running Android 5.0 Lollipop or later.
This sample uses the Gradle build system. To build this project, use the "gradlew assemble" command or use "Import Project" in Android Studio.
ou can find various kinds of provisioning methods here. Let's take a few of them as an example.QR code provisioing (Device Owner N+ only)
- Factory reset your device and tap the welcome screen in setup wizard 6 times.
- The setup wizard prompts the user to connect to the Internet so the setup wizard can download a QR code reader.
- Modify (if needed) and scan [this QR code] (http://down-box.appspot.com/qr/nQB0tw7b).
- Follow onscreen instructions
The NFC Provisioning app is used for device owner provisioning.
- Push the nfcprovisioning.txt file to your device:
adb push nfcprovisioning.txt /sdcard/
- Open the NFC Provisioning app and ensure that com.afwsamples.testdpc is auto-populated.
- Bump the devices and touch to beam.
- Follow onscreen instructions on the target device.
adb shell dpm set-device-owner com.afwsamples.testdpc/.DeviceAdminReceiverWork profile
The easiest way is to launch the Test DPC app in launcher and follow the onscreen instructions.Know more about test dpc : https://github.com/googlesamples/android-testdpc
Also read : how to uninstall test dpc