# Tasks: Enrollment & Autopilot (014)

**Branch**: `014-enrollment-autopilot` | **Date**: 2026-01-01
**Input**: [spec.md](./spec.md), [plan.md](./plan.md)

## Phase 1: Contracts Review
- [x] T001 Verify `config/graph_contracts.php` entries for:
  - `windowsAutopilotDeploymentProfile`
  - `windowsEnrollmentStatusPage`
  - `enrollmentRestriction`
  (resource, type_family, create/update methods, assignment paths/payload keys)
- [x] T002 Verify `config/tenantpilot.php` entries and restore modes:
  - Autopilot/ESP = `enabled`
  - Enrollment restrictions = `preview-only`

## Phase 2: UI Normalization
- [x] T003 Add an `EnrollmentAutopilotPolicyNormalizer` (or equivalent) that produces readable normalized settings for the three policy types.
- [x] T004 Register the normalizer in the app container/provider (tag `policy-type-normalizers`).

## Phase 3: Restore Safety
- [x] T005 Add a feature test verifying `enrollmentRestriction` restore is preview-only and skipped on execution (no Graph apply calls).

## Phase 3b: Enrollment Configuration Type Collisions
- [x] T005b Fix ESP vs enrollment restriction collision on `deviceEnrollmentConfigurations` sync (canonical type resolution + safe reclassification).

## Phase 4: Tests + Verification
- [x] T006 Add unit tests for normalized output (shape + stability) for the three policy types.
- [x] T007 Add Filament render tests for “Normalized settings” tab for the three policy types.
- [x] T008 Run targeted tests.
- [x] T009 Run Pint (`./vendor/bin/pint --dirty`).

## Open TODOs (Follow-up)
- None.
