# googlesamples/android-testdpc

Test DPC is a sample device policy controller for use with Android Enterprise. It gives developers the ability to see how their app will behave in a managed context such as device owner or within a managed profile. Users can set up a work profile, enable work apps, set applications restrictions, manage security polices, and much more. The app also serves as a implementation reference for other DPCs

Repository: https://github.com/googlesamples/android-testdpc
Canonical: https://ross.abutalabs.com/products/android-testdpc
Homepage: https://play.google.com/store/apps/details?id=com.afwsamples.testdpc
Language: Java
License: Apache-2.0
License Family: permissive
Last push: 2026-01-29T17:10:31+00:00

## Health v2 (maintenance only)
Score: 52/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 64, release rhythm 8, longevity 100
- inputs: {"age_days": 4121, "days_push": 216, "days_rel": 723, "gap_med": null, "n_releases_24m": 1}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1030, forks 419 (observed 2026-08-28T04:03:17.827486+00:00)

## What it is
Test DPC is a sample Device Policy Controller app for Android Enterprise that lets developers test how their apps behave in managed contexts like device owner or work profiles. It also serves as an implementation reference for other DPCs and supports provisioning via QR code, ADB, or AFW# code.

## Use cases
- test my app in an android work profile
- set up a device owner on android for testing
- see how my app behaves under enterprise management policies
- provision a fully managed device with a QR code
- reference implementation for building a device policy controller
- manage security policies and app restrictions on a test device

## When to choose
- you are an EMM, ISV, or OEM testing apps against Android Enterprise APIs
- you need to simulate device owner or profile owner scenarios
- you want a reference implementation of Android device policy APIs

## When to avoid
- you need a production DPC for managing real enterprise fleets
- you are not working with Android Enterprise managed devices or profiles

## Facets
- artifact type: application
- maturity: active
- function: testing, security, developer-tools
- domain: android-tools, developer-tools, security, testing
- platform: -
- tags: device-policy-controller, android-enterprise, work-profile, emm, sample-app, device-owner, provisioning, android

## Member repositories
- googlesamples/android-testdpc (main) score 52

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:03:17.827486+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T07:07:33.756630+00:00, confidence not recorded.
  - readme: https://github.com/googlesamples/android-testdpc (fetched 2026-08-28T04:03:17.827486+00:00, sha 237a8ff0088d)
  - homepage: https://play.google.com/store/apps/details?id=com.afwsamples.testdpc (fetched 2026-08-29T13:07:01.353978+00:00, sha 44136fa355b3)
- Data as of 2026-08-30T08:39:29.467469+00:00.
