Testing
This guide summarizes current testing commands and recommended local checks.
Backend tests
Backend tests run with Laravel's test runner (PHPUnit integration).
powershell
cd backend
php artisan testRun a specific test file:
powershell
php artisan test tests/Feature/AuthTest.phpRecommended backend smoke checks
After major backend changes, validate:
- auth login and logout
- role-restricted endpoint behavior
- core CRUD endpoints (courses, lessons, quizzes, questions)
- results reset behavior
- invite create and accept flows
- assignment create and update flows
Frontend checks
There is no dedicated frontend test suite currently configured.
Use these quality gates:
powershell
cd frontend
npm run lint
npm run buildManual regression checklist:
- login as employee and admin
- employee course flow (lesson complete, quiz submit)
- admin content edit and publish toggles
- assignments and invites workflows
- route guard redirects
Docs checks
Validate docs after any markdown or theme update:
powershell
cd docs
npm run docs:buildUse docs dev server while editing:
powershell
npm run docs:devCI recommendation
If CI is introduced or extended, include:
- backend
php artisan test - frontend
npm run lintandnpm run build - docs
npm run docs:build