Skip to content

test: golden-master regression for scenario #0 (#38)#47

Open
thc1006 wants to merge 1 commit into
developfrom
enh/scenario-0-regression
Open

test: golden-master regression for scenario #0 (#38)#47
thc1006 wants to merge 1 commit into
developfrom
enh/scenario-0-regression

Conversation

@thc1006

@thc1006 thc1006 commented Jun 27, 2026

Copy link
Copy Markdown
Member

Adds a golden-master regression test for scenario #0. Part of #38.

Scenario #0 is deterministic (static balloons, fixed seed, ideal sensors, no Monte Carlo), so the default agent produces a reproducible rocket trajectory. The test re-runs it and compares against a committed baseline, guarding against unintended physics changes when ActiveRocketPy is updated.

  • Compares popped count (exact, == 10), the rocket position trajectory (rtol=0.03, atol=1 m), and flight duration (within 2%).
  • Baseline = downsampled post-launch positions in tests/baselines/scenario_0.json; regenerate deliberately via tests/baselines/regenerate_scenario_0.py and review the diff when a physics change is intended.
  • Side-effect-free runner; guarded with skipUnless like the other runtime tests.

Scope: scenario #0 only; scenario #1 (Monte Carlo) is left for a follow-up nightly test. Measured ~12 s, and the baseline is identical across numpy 2.4.5/2.5.0 and Python 3.13/3.14.

Re-runs scenario #0 (deterministic: static balloons, fixed seed, ideal
sensors, no Monte Carlo) with the default agent and compares against a
committed baseline, guarding against unintended physics changes when
ActiveRocketPy is updated.

- Compares popped count (exact, == 10), rocket position trajectory
  (rtol 3%, atol 1 m), and flight duration (within 2%).
- Baseline is downsampled post-launch positions; regenerate deliberately
  via tests/baselines/regenerate_scenario_0.py and review the diff.
- Side-effect free runner; guarded with skipUnless like the other runtime tests.
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