Skip to content

feat: add testing pattern guides (contract, scenario, progression)#43

Open
keugenek wants to merge 1 commit intomainfrom
evgenii.kniazev/testing-patterns
Open

feat: add testing pattern guides (contract, scenario, progression)#43
keugenek wants to merge 1 commit intomainfrom
evgenii.kniazev/testing-patterns

Conversation

@keugenek
Copy link
Copy Markdown
Contributor

@keugenek keugenek commented Apr 1, 2026

Summary

Stacked on #41 (proto-first reference).

Adds 3 testing pattern guides to databricks-apps/references/appkit/:

1. contract-testing.md

PACT-style contract tests for AppKit apps. Covers:

  • 4 boundary types: frontend↔server, server↔lakebase, server↔files, job↔job
  • Vitest examples for each boundary
  • Proto-first contract derivation workflow
  • Not mandatory — use when app has multiple data producers/consumers

2. scenario-testing.md

Playwright e2e tests using the pw-evals pattern. Covers:

  • Directory structure: meta.json + public/private cases.json + specs
  • Parameterized Playwright tests with ARIA selectors
  • Public/private split for eval-driven development
  • Not mandatory — use for apps needing UI-level acceptance testing

3. testing-patterns.md

5-level testing progression. Covers:

  • Level 1: Smoke tests (mandatory — generated by appkit init)
  • Level 2: Unit tests (vitest)
  • Level 3: Contract tests (PACT-style)
  • Level 4: Scenario tests (Playwright + JSON cases)
  • Level 5: Eval pipeline (automated at scale)
  • Only Level 1 is mandatory; add levels incrementally

Also updates SKILL.md Required Reading table with all three guides.

Documentation safety checklist

  • Examples use least-privilege permissions
  • Sensitive values obfuscated
  • No insecure patterns

@keugenek keugenek requested a review from a team as a code owner April 1, 2026 15:53
@keugenek keugenek force-pushed the evgenii.kniazev/proto-first-skill branch from f9cf254 to bdb9815 Compare April 1, 2026 16:28
@keugenek keugenek requested a review from lennartkats-db as a code owner April 1, 2026 16:28
Adds 3 testing guides to databricks-apps/references/appkit/:

- contract-testing.md: PACT-style contract tests for cross-boundary
  data validation (frontend↔server, server↔lakebase, job↔job)
- scenario-testing.md: Playwright e2e tests parameterized by JSON
  cases using the pw-evals pattern (public/private split)
- testing-patterns.md: 5-level testing progression from smoke tests
  (mandatory) through unit, contract, scenario, to eval pipeline

Updates SKILL.md Required Reading table with all three.
@keugenek keugenek force-pushed the evgenii.kniazev/testing-patterns branch from 8fabdf2 to e3fe71a Compare April 1, 2026 16:30
@keugenek keugenek changed the base branch from evgenii.kniazev/proto-first-skill to main April 1, 2026 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant