docs: comprehensive test behavior documentation for all pages #6

Merged
notid merged 3 commits from test-plan-docs into master 2026-05-04 13:55:03 -07:00
Owner

Summary

Adds comprehensive behavior documentation covering every page and subsystem in Integreat. This is the foundation for a full test coverage effort.

What's Included

Strategy Document

  • docs/testing/README.md — Test type definitions (unit/integration/UI), existing test inventory, coverage map, priorities, test data patterns, mocks, and running instructions

Behavior Documents (12 subsystem docs, 3,600+ lines)

Document Pages SSR UI Tests
behaviors/invoice.md List, wizard, pay, bulk edit/delete, import, glimpse (OCR) Yes
behaviors/admin.md Dashboard, clients, accounts, vendors, rules, jobs, history, imports Yes
behaviors/transaction.md List, new, external import, admin insights/coding Yes
behaviors/ledger.md Entries, P&L, balance sheet, cash flows, investigation Yes
behaviors/company.md Profile, 1099s, reports, Plaid/Yodlee linking, signature Yes
behaviors/legacy-spa.md Home, login, transactions, ledger, payments, reports, vendors Docs only
behaviors/payment.md List, detail, bulk delete, check printing Yes
behaviors/pos.md Sales, deposits, tenders, refunds, cash drawer shifts Yes
behaviors/dashboard.md Cards (expenses, tasks, bank accounts, sales, P&L) Yes
behaviors/outgoing-invoice.md Create, line items, PDF generation Yes
behaviors/auth.md Login, logout, impersonation, Google OAuth Yes
behaviors/search-indicators.md Global search, business indicators Yes

Each document includes all routes, unit/integration/UI test behaviors, edge cases, test data requirements, dependencies, and notes on existing tests to preserve.

Test Strategy

  • Unit tests: Pure functions, transformations, business logic
  • Integration tests: Datomic in-memory DB, GraphQL resolvers, route handlers
  • UI tests (Playwright): Only for SSR pages; legacy SPA pages get behavior docs only until migrated

Next Steps

These docs are ready to guide incremental test authorship. Priority order:

  1. Invoice pages (core business function)
  2. Payment pages (money movement)
  3. Dashboard (first user experience)
  4. Transaction pages (data entry/coding)
## Summary Adds comprehensive behavior documentation covering every page and subsystem in Integreat. This is the foundation for a full test coverage effort. ## What's Included **Strategy Document** - docs/testing/README.md — Test type definitions (unit/integration/UI), existing test inventory, coverage map, priorities, test data patterns, mocks, and running instructions **Behavior Documents (12 subsystem docs, 3,600+ lines)** | Document | Pages | SSR UI Tests | |----------|-------|-------------| | behaviors/invoice.md | List, wizard, pay, bulk edit/delete, import, glimpse (OCR) | Yes | | behaviors/admin.md | Dashboard, clients, accounts, vendors, rules, jobs, history, imports | Yes | | behaviors/transaction.md | List, new, external import, admin insights/coding | Yes | | behaviors/ledger.md | Entries, P&L, balance sheet, cash flows, investigation | Yes | | behaviors/company.md | Profile, 1099s, reports, Plaid/Yodlee linking, signature | Yes | | behaviors/legacy-spa.md | Home, login, transactions, ledger, payments, reports, vendors | Docs only | | behaviors/payment.md | List, detail, bulk delete, check printing | Yes | | behaviors/pos.md | Sales, deposits, tenders, refunds, cash drawer shifts | Yes | | behaviors/dashboard.md | Cards (expenses, tasks, bank accounts, sales, P&L) | Yes | | behaviors/outgoing-invoice.md | Create, line items, PDF generation | Yes | | behaviors/auth.md | Login, logout, impersonation, Google OAuth | Yes | | behaviors/search-indicators.md | Global search, business indicators | Yes | Each document includes all routes, unit/integration/UI test behaviors, edge cases, test data requirements, dependencies, and notes on existing tests to preserve. ## Test Strategy - Unit tests: Pure functions, transformations, business logic - Integration tests: Datomic in-memory DB, GraphQL resolvers, route handlers - UI tests (Playwright): Only for SSR pages; legacy SPA pages get behavior docs only until migrated ## Next Steps These docs are ready to guide incremental test authorship. Priority order: 1. Invoice pages (core business function) 2. Payment pages (money movement) 3. Dashboard (first user experience) 4. Transaction pages (data entry/coding)
notid added 1 commit 2026-05-04 12:16:52 -07:00
Add behavior documentation covering all SSR and legacy SPA pages:
- Testing strategy and type definitions (unit/integration/UI)
- Dashboard, Invoice, Payment, Transaction, Ledger pages
- Company/Settings, POS, Admin, Search, Auth pages
- Legacy SPA behavior docs (no UI tests until migrated)
- Edge cases, test data requirements, and dependencies per subsystem

Total: 3,600+ lines of behavior documentation to guide test authorship.
notid added 1 commit 2026-05-04 13:31:05 -07:00
- Add testing patterns section (Grid Page, Wizard, Permission Gates)
- Convert all behaviors to numbered tables with checkboxes
- Specify test strategy per behavior (Unit/Integration/UI)
- Group by feature area: Display, Filter, Sort, Pay Wizard, etc.
- Add cross-cutting Permissions and Lock Date tables
- Reduce from 496 to 403 lines while being more comprehensive
notid added 1 commit 2026-05-04 13:48:53 -07:00
Rewrite all 11 remaining behavior documents to match the streamlined
invoice.md format:

- dashboard.md: 250 lines, 62 behaviors
- payment.md: 260 lines, behaviors for list, void, check printing, ACH
- transaction.md: 310 lines, list, import, admin insights
- ledger.md: 519 lines, entries, P&L, balance sheet, cash flows
- company.md: 320 lines, profile, 1099s, Plaid/Yodlee, reports
- admin.md: 494 lines, clients, accounts, vendors, rules, jobs, history
- pos.md: 405 lines, sales, deposits, tenders, refunds, shifts
- search-indicators.md: 167 lines, search modal, indicators
- auth.md: 184 lines, login, logout, impersonation, sessions
- outgoing-invoice.md: 192 lines, create, line items, PDF
- legacy-spa.md: 340 lines, all legacy pages (docs only)

All documents now use:
- Testing Patterns section with reusable abstractions
- Numbered tables: # | Behavior | Test Strategy | Status
- It should... behavior descriptions
- Checkboxes [ ]/[x] for tracking implementation
- Cross-Cutting Behaviors for permissions, lock dates, etc.
- Test Data Requirements tables
- Existing Tests to Preserve sections

Total: 3,844 lines of behavior documentation across 12 subsystem docs.
notid merged commit a78c818270 into master 2026-05-04 13:55:03 -07:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: notid/integreat#6