Testing

Use this page as the quick testing entry point. The detailed contributor workflow still lives in Contributing.

Common Commands

Need

Command

Routine local regression pass

uv run poe test-fast

Browser smoke for the main form flow

uv run poe test-browser-smoke

Runtime guardrails

uv run poe perf-guardrails

Lint, formatting, license, and fast tests

uv run poe prepush-fast

Broader docs/browser pre-push gate

uv run poe prepush-full

Coverage

uv run poe test-fast runs the main non-WebKit suite, writes cover/coverage.json, and refreshes the generated coverage map, reproduced below.

Use this generated map as a quick sense of which workflows are well covered before changing a shared route or template. Percentages come from the latest poe test-fast pytest-cov JSON run.

Overall labfrog line coverage from that run: 80.00%.

Area

Coverage

Main tests

Watch next

Startup, auth, and request state

71% Good

tests/test_app_factory.py, tests/test_public_routes.py, tests/test_helper_functions.py, tests/test_route_health.py

Environment-specific branches and login provider edge cases

Add Entry / Edit Entry

83% Good

tests/test_tab_routes.py, tests/test_navigation_routes.py, tests/test_target_series.py, tests/test_webkit_forms.py, tests/test_form_save_integrity.py, tests/test_ui_layout_invariants.py, tests/test_copy_forward.py, tests/test_entry_save_failure.py, tests/test_shot_details_routes.py, tests/test_offline_resilience.py

Less common set-mode and shot-number backfeed branches

Search Records

80% Good

tests/test_search_form.py

Drag/resize-heavy browser behavior around plots

Select Fields / Organize Sections

86% Strong

tests/test_management_workflows.py, tests/test_section_headers_mode.py, tests/test_shot_day_grouping.py, tests/test_form_save_integrity.py, tests/test_form_save_fidelity.py, tests/test_ui_layout_invariants.py, tests/test_audit_layout_fields.py

Campaign-mapped layout resolution across paired shot/set modes

Parameters, diagnostics, and selectables

76% Good

tests/test_management_workflows.py, tests/test_phase1_regression.py, tests/test_custom_selectables.py, tests/test_mediawiki_selectables.py, tests/test_form_save_fidelity.py

Diagnostic preset detail round-trips and option de-duplication

Init, reset, and operator tooling

79% Good

tests/test_init_db.py, tests/test_dev_tasks.py, tests/test_kafka_listener.py, tests/test_kafka_integration.py, tests/test_scheduled_backup.py

Real-service integration branches

Test Areas

Area

Main tests

Add/Edit Entry and navigation

test_tab_routes.py, test_navigation_routes.py, test_phase1_regression.py, test_shot_day_grouping.py, test_target_series.py, test_shot_details_routes.py, test_copy_forward.py

Saving, and not losing operator work

test_form_save_fidelity.py, test_form_save_integrity.py, test_entry_save_failure.py, test_offline_resilience.py

Search Records

test_search_form.py

Layout and management workflows

test_management_workflows.py, test_section_headers_mode.py, test_audit_layout_fields.py, test_ui_layout_invariants.py

App factory and the routing surface

test_app_factory.py, test_public_routes.py, test_route_health.py, test_helper_functions.py

Database initialization and read-only protections

test_init_db.py

Unattended MongoDB backup and retention

test_scheduled_backup.py

MediaWiki and custom selectable adapters

test_mediawiki_selectables.py, test_custom_selectables.py

Kafka listener behavior

test_kafka_listener.py, test_kafka_integration.py (Docker)

Analysis configs and data access

test_analysis_configs.py, test_analysis_data_access.py

Runtime performance and benchmarks

test_runtime_performance.py, test_benchmark_wrapper.py, test_benchmark_refresh_docs.py

Docs and coverage tooling

test_coverage_docs.py, test_docs_sync.py, test_dev_tasks.py

Browser smoke (WebKit)

test_webkit_forms.py

All paths are under tests/. This table is meant to cover the whole suite: if you add a test module, add it to a row here.

Slower Or Optional Checks

  • WebKit browser smoke tests use Playwright and cover Add/Edit form rendering, session-cookie reuse, and draft preservation across navigation. They are separated with the webkit marker.

  • Kafka integration tests use Docker and are separated with the kafka marker.

  • Benchmark runners are documented on the Benchmarks page.