Attendance API Testing Guide
Summary
This guide organizes source-backed test areas without instructing tests against production.
Audience
QA engineers, developers, architects, support engineers, and implementation partners.
Test layers
- Contract tests: direct envelope versus compatibility bare bodies, binding, status mapping, and correlation behavior.
- Application integration tests: records, calculation, workflow, audit, tenant filters, and persistence side effects.
- Gateway tests: direct/shadow, compatibility owner, independent Time Office cutover, and rollback.
- Payroll dependency tests: locked/unlocked results, unavailable dependency behavior in an approved isolated environment, and no mutation on a locked reopen.
- Smoke/parity/cutover tests: existing scripts cover service flow, compatibility, routing, backfill parity, and go/no-go decisions.
- Negative/security tests: missing/mismatched tenant, self-versus-approver scope, administrator-only Time Office mutations, and cross-tenant isolation.
Coverage matrix
| Area | Confirmed cases to test |
|---|---|
| Records | Save/update-by-date, date-range and employee filters, approved-period query, invalid employee/profile, weekly-off entry, missing tenant, month validation; ordinary future-date rule requires confirmation. |
| Punches | Valid in/out or explicit hours, multiple punches, missing duration, weekly-off work, approval/rejection, not-found; duplicate/sequence rules and correction are unsupported or unconfirmed. |
| Calculation | Direct/Hourly, Present/HalfDay/Absent, overtime, shortfall, paid units, approval recalculation, policy fallback. |
| Submission | Pending save, authorized approved save, pending query, approve, reject, not-found, audit and high-level event side effects. |
| Reopening | Create, duplicate pending conflict, future date, locked period, approve/reject, terminal-state validation, audit. |
| Time Office | Shift create/update/deactivate, active assignment conflict, effective range, weekly-off validation, default/active policy, embedded policy rules. |
| Routing | Direct service, compatibility, shadow validation, cutover owner, parity, rollback. |
Use synthetic tenants, fictional employee identifiers, and non-customer policy values. No Attendance-specific formal .NET test project was found. Existing PowerShell assets are evidence of smoke/cutover coverage; CI execution remains Requires confirmation.
Source References
microservices/scripts/smoke-attendance.ps1microservices/scripts/compare-attendance-shift-parity.ps1microservices/scripts/attendance-shift-cutover-go-no-go.ps1microservices/docs/attendance-shift-cutover-runbook.mdmicroservices/src/attendance-service/Application/Services/AttendanceCommands.csmicroservices/src/attendance-service/Application/Services/PunchWorkflow.csmicroservices/src/attendance-service/Application/Services/ReopenRequestWorkflow.cs
Related Articles
See Also
Keywords
- Attendance API
- Attendance API Testing Guide
Revision Information
- Status: Draft
- Last reviewed: 2026-07-15
- Review cycle: Quarterly