.remote-cache/kreuzberg-shared-rules/.ai-rulez/skills/testing-philosophy-coverage/SKILL.md
______________________________________________________________________ ## priority: critical # Testing Philosophy & Coverage **Three-tier**: unit (80-95%), integration (real DB/services), E2E (smoke/full) **Real infrastructure in tests**: PostgreSQL, Redis, not mocks **Rust**: cargo test, #[tokio::test], 95% coverage (tarpaulin), test error paths, edge cases, no panics **Python**: Function-based tests only (\*_test.py), pytest fixtures, 95% coverage. Structure: tests/{core,features,integra
npx skillsauth add kreuzberg-dev/html-to-markdown .remote-cache/kreuzberg-shared-rules/.ai-rulez/skills/testing-philosophy-coverageInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Three-tier: unit (80-95%), integration (real DB/services), E2E (smoke/full)
Real infrastructure in tests: PostgreSQL, Redis, not mocks
Rust: cargo test, #[tokio::test], 95% coverage (tarpaulin), test error paths, edge cases, no panics
Python: Function-based tests only (*test.py), pytest fixtures, 95% coverage. Structure: tests/{core,features,integration,interfaces,extractors,ocr,utils,e2e}. Test async+sync, error paths. Naming: test<function><scenario><outcome>. NEVER mock anyio/asyncio, prefer real objects (tmp_path).
TypeScript: .spec.ts next to source files, vitest, 80%+ coverage
Go: *_test.go with _test package suffix (black-box), table-driven with t.Run(), 80%+ business logic, go test -race
Ruby: RSpec, describe/context/it blocks, 80%+ coverage
Java: JUnit 5, @Test methods, AssertJ, 80%+ coverage. E2E auto-generated from fixtures.
tools
Convert HTML to Markdown, Djot, or plain text with structured extraction. Use when writing code that calls html-to-markdown APIs in Rust, Python, TypeScript, Go, Ruby, PHP, Java, C#, Elixir, R, C, or WASM. Covers installation, conversion, configuration, metadata extraction, document structure, and CLI usage.
development
Developer quick start guide with prerequisites, setup, and workflow commands
development
Common task runner commands for build, test, lint, and format workflows
tools
______________________________________________________________________ ## priority: high # Workspace Structure & Project Organization **Rust workspace** (Cargo.toml): crates/{kreuzberg,kreuzberg-py,kreuzberg-node,kreuzberg-ffi,kreuzberg-cli}, packages/ruby/ext/kreuzberg_rb/native, tools/{benchmark-harness,e2e-generator}, e2e/{rust,go}. **Language packages**: packages/{python,typescript,ruby,java,go} - thin wrappers around Rust core. **E2E tests**: Auto-generated from fixtures/ via tools/e2e