Skip to content

Commit 3330c5a

Browse files
Merge branch 'develop' into bug/3d-trajectory-plot
2 parents 59a5498 + b221d88 commit 3330c5a

File tree

4 files changed

+27
-17
lines changed

4 files changed

+27
-17
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ You can install this version by running `pip install rocketpy==1.2.0`
7171
### Fixed
7272

7373
- BUG: Update flight trajectory plot axes limits [#552](https://github.com/RocketPy-Team/RocketPy/pull/552)
74+
- BUG: fix `get_controller_observed_variables` in the air brakes examples [#551](https://github.com/RocketPy-Team/RocketPy/pull/551)
7475
- MNT: small fixes before v1.2 [#550](https://github.com/RocketPy-Team/RocketPy/pull/550)
7576
- BUG: Elliptical Fins Draw [#548](https://github.com/RocketPy-Team/RocketPy/pull/548)
7677
- BUG: 3D trajectory plot not labeling axes [#533](https://github.com/RocketPy-Team/RocketPy/pull/533)

docs/notebooks/air_brakes_example.ipynb

Lines changed: 15 additions & 16 deletions
Large diffs are not rendered by default.

docs/user/airbrakes.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,9 @@ Then we can plot the data we want.
401401

402402
time_list, deployment_level_list, drag_coefficient_list = [], [], []
403403

404-
for time, deployment_level, drag_coefficient in test_flight.get_controller_observed_variables:
404+
obs_vars = test_flight.get_controller_observed_variables()
405+
406+
for time, deployment_level, drag_coefficient in obs_vars:
405407
time_list.append(time)
406408
deployment_level_list.append(deployment_level)
407409
drag_coefficient_list.append(drag_coefficient)

tests/unit/test_flight.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,3 +250,11 @@ def test_export_kml(flight_calisto_robust):
250250
assert np.allclose(test_flight.latitude[:, 1], lat, atol=1e-3) == True
251251
assert np.allclose(test_flight.longitude[:, 1], lon, atol=1e-3) == True
252252
assert np.allclose(test_flight.z[:, 1], z, atol=1e-3) == True
253+
254+
255+
def test_get_controller_observed_variables(flight_calisto_air_brakes):
256+
"""Tests whether the method Flight.get_controller_observed_variables is
257+
working as intended."""
258+
obs_vars = flight_calisto_air_brakes.get_controller_observed_variables()
259+
assert isinstance(obs_vars, list)
260+
assert len(obs_vars) == 0

0 commit comments

Comments
 (0)