STAR
Cal STAR — firmware, DAQ server, and engine design
Loading...
Searching...
No Matches
conftest Namespace Reference

Functions

None pytest_collection_modifyitems (list[pytest.Item] items)
 pytest_collection_modifyitems (config, items)

Variables

dict SLOW_TESTS
dict _QUARANTINE_FILES
str _STALE_8_STATE = "stale: written for legacy 8-state model (now 11 states)"
dict _QUARANTINE_TESTS

Detailed Description

Test tiers for the physics core.

The fast tier (`scripts/check.sh`, `pytest -m "not slow"`) leaves out the tests
that integrate a whole burn; CI runs everything. Measured 2026-10-06 with
`--durations`: each of these took over ~3.5 s. Re-measure before adding to it.
CI quarantine for stale EngineDesign tests (non-control).

These tests fail on the current ``main`` for reasons unrelated to any change
under review — they were written against an older API / different default
constants and were never updated. A test that is already red on a clean tree
cannot act as a regression guard, so per the project's CI philosophy (gate on
guards that catch *new* breakage, not on pre-existing drift) they are skipped
here rather than blocking the gate.

Each entry records *why* it is quarantined and how to revive it. The intent is
for this list to shrink to empty: fix the test (or delete it if truly dead) and
remove its entry. Nothing here deletes a test — the code stays visible.

The robust-DDP controller suite has its own, larger quarantine in
``tests/control/robust_ddp/conftest.py``.
CI quarantine for the robust-DDP controller test suite.

These tests were written against a *legacy 8-state* dynamics model. The
controller's state vector has since grown to 11 states (see
``engine/control/robust_ddp/dynamics.py``: ``N_STATE``), so a large block of
the suite now fails with shape errors (``w_bar must have shape (11,), got
(8,)``) or stale-API errors (``TypeError: keywords must be strings``) rather
than physics drift. A few are emergent-value checks whose tolerances no longer
match the current model.

Per the project's CI philosophy — gate on regression guards (structure,
contracts, "does it still run"), not on outputs that legitimately change when
the physics/model is retuned — these stale/brittle tests are *quarantined*:
they are skipped in collection so they do not gate CI, while the ~70 structural
controller tests that still pass keep guarding against regressions.

To un-quarantine a test once it has been updated for the 11-state model, delete
its entry below. The goal is for this list to shrink to empty over time.

Nothing here deletes a test — it only skips it, so the intent stays visible.

Function Documentation

◆ pytest_collection_modifyitems() [1/2]

conftest.pytest_collection_modifyitems ( config,
items )

Definition at line 91 of file conftest.py.

◆ pytest_collection_modifyitems() [2/2]

None conftest.pytest_collection_modifyitems ( list[pytest.Item] items)

Definition at line 31 of file conftest.py.

Variable Documentation

◆ _QUARANTINE_FILES

dict conftest._QUARANTINE_FILES
protected
Initial value:
1= {
2 "test_layer1_bounds_fix.py": (
3 "DEAD: imports `Layer1OptimizerConfig` from "
4 "engine.optimizer.layers.layer1_static_optimization, which no longer "
5 "exists anywhere in the codebase. The file cannot import. "
6 "Fix: update to the current optimizer-config API or delete."
7 ),
8}

Definition at line 21 of file conftest.py.

◆ _QUARANTINE_TESTS

dict conftest._QUARANTINE_TESTS
protected

Definition at line 42 of file conftest.py.

◆ _STALE_8_STATE

str conftest._STALE_8_STATE = "stale: written for legacy 8-state model (now 11 states)"
protected

Definition at line 41 of file conftest.py.

◆ SLOW_TESTS

dict conftest.SLOW_TESTS
Initial value:
1= {
2 "test_chamber_pressure_moves_less_than_tank_pressure",
3 "test_a_layer1_engine_fires_on_a_real_feed_system",
4 "test_mixture_ratio_drifts_over_a_burn",
5 "test_a_chilling_tank_climbs_and_climbs_more_the_harder_the_dewar_pushes",
6 "test_radau_agrees_with_bdf",
7 "test_expulsion_matches_closed_form",
8 "test_the_ox_lead_shows_up_in_the_trace",
9 "test_expulsion_deviation_is_the_compressibility",
10 # LE4 with its cart drawn (2026-10-07): a LOX load from a drawn dewar is a
11 # minute of cryogen numerics, the fuel pad and the dome pad seconds each.
12 "test_ox_fill_loads_the_flight_lox_tank_from_the_dewar",
13 "test_the_pad_charges_the_copv_and_loads_fuel_through_the_drawing",
14 "test_the_dome_loads_on_the_pad_and_holds_when_its_valve_shuts",
15 # 50 s of a vented LOX load (2026-11-02), ~18 s.
16 "test_a_vented_lox_load_keeps_its_ullage_over_the_liquid",
17}

Definition at line 12 of file conftest.py.