Skip to content

Commit

Permalink
TST: add barometric_height to tests
Browse files Browse the repository at this point in the history
  • Loading branch information
MateusStano authored and Gui-FernandesBR committed Jan 20, 2024
1 parent 2b06a7e commit e787b11
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/test_environment.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ def test_standard_atmosphere(mock_show, example_env):
assert example_env.info() == None
assert example_env.all_info() == None
assert abs(example_env.pressure(0) - 101325.0) < 1e-8
assert example_env.barometric_height(101325.0) < 1e-2
assert example_env.prints.print_earth_details() == None


Expand All @@ -43,6 +44,7 @@ def test_custom_atmosphere(mock_show, example_env):
)
assert example_env.all_info() == None
assert abs(example_env.pressure(0) - 101325.0) < 1e-8
assert example_env.barometric_height(101325.0) < 1e-2
assert abs(example_env.wind_velocity_x(0) - 5) < 1e-8
assert abs(example_env.temperature(100) - 300) < 1e-8

Expand Down Expand Up @@ -71,6 +73,7 @@ def test_wyoming_sounding_atmosphere(mock_show, example_env):
pass
assert example_env.all_info() == None
assert abs(example_env.pressure(0) - 93600.0) < 1e-8
assert example_env.barometric_height(example_env.pressure(0)) == 722.0
assert abs(example_env.wind_velocity_x(0) - -2.9005178894925043) < 1e-8
assert abs(example_env.temperature(100) - 291.75) < 1e-8

Expand Down

0 comments on commit e787b11

Please sign in to comment.