afc163
|
4e4f842e8d
|
test: add core page test coverage (#11824)
Add Vitest test suites for core modules and pages:
- access.ts: 100% coverage (canAdmin permission logic)
- requestErrorConfig.ts: 100% coverage (errorThrower, errorHandler for all
showType branches, request interceptor token attachment)
- app.tsx getInitialState: currentUser fetch, 401 redirect with path
encoding, login-page skip path
- table-list (ProTable): 53% — column rendering, request invocation
- basic-form (ProForm): 86% — field rendering, submit handling
- dashboard/analysis: data fetching and child component data flow
Register @testing-library/jest-dom matchers in setupTests for DOM
assertions. 42 tests total.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
4 months ago |