From dce20809f94b2d2d9a328a309df8d31fe15405c7 Mon Sep 17 00:00:00 2001 From: Lint Action Date: Tue, 13 Feb 2024 21:53:05 +0000 Subject: [PATCH] Fix code style issues with Black --- tests/conftest.py | 5 ++--- tests/fixtures/environment/environment_fixtures.py | 2 +- tests/fixtures/function/function_fixtures.py | 2 +- tests/fixtures/hybrid/hybrid_fixtures.py | 14 +++++++++++--- tests/fixtures/motor/motor_fixtures.py | 3 +-- tests/fixtures/rockets/rocket_fixtures.py | 2 +- tests/fixtures/surfaces/surface_fixtures.py | 1 - tests/fixtures/units/numerical_fixtures.py | 2 +- 8 files changed, 18 insertions(+), 13 deletions(-) diff --git a/tests/conftest.py b/tests/conftest.py index 597cc9bc6..88e6fa683 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -12,11 +12,12 @@ "tests.fixtures.parachutes.parachute_fixtures", "tests.fixtures.rockets.rocket_fixtures", "tests.fixtures.surfaces.surface_fixtures", - "tests.fixtures.units.numerical_fixtures" + "tests.fixtures.units.numerical_fixtures", ] # + def pytest_addoption(parser): """Add option to run slow tests. This is used to skip slow tests by default. @@ -76,5 +77,3 @@ def pytest_collection_modifyitems(config, items): ## Functions - - diff --git a/tests/fixtures/environment/environment_fixtures.py b/tests/fixtures/environment/environment_fixtures.py index 2864efdb3..54bc8bcce 100644 --- a/tests/fixtures/environment/environment_fixtures.py +++ b/tests/fixtures/environment/environment_fixtures.py @@ -70,4 +70,4 @@ def env_analysis(): max_expected_altitude=None, ) - return env_analysis \ No newline at end of file + return env_analysis diff --git a/tests/fixtures/function/function_fixtures.py b/tests/fixtures/function/function_fixtures.py index c52f4fecf..566e4d115 100644 --- a/tests/fixtures/function/function_fixtures.py +++ b/tests/fixtures/function/function_fixtures.py @@ -137,4 +137,4 @@ def lambda_quad_func(): func = lambda x: x**2 return Function( source=func, - ) \ No newline at end of file + ) diff --git a/tests/fixtures/hybrid/hybrid_fixtures.py b/tests/fixtures/hybrid/hybrid_fixtures.py index 471e7a8bf..9c3d8c8dc 100644 --- a/tests/fixtures/hybrid/hybrid_fixtures.py +++ b/tests/fixtures/hybrid/hybrid_fixtures.py @@ -1,9 +1,17 @@ import numpy as np import pytest -from rocketpy import (CylindricalTank, Fluid, Function, HybridMotor, - LevelBasedTank, LiquidMotor, MassBasedTank, - SphericalTank, UllageBasedTank) +from rocketpy import ( + CylindricalTank, + Fluid, + Function, + HybridMotor, + LevelBasedTank, + LiquidMotor, + MassBasedTank, + SphericalTank, + UllageBasedTank, +) @pytest.fixture diff --git a/tests/fixtures/motor/motor_fixtures.py b/tests/fixtures/motor/motor_fixtures.py index ca374164a..f53457d49 100644 --- a/tests/fixtures/motor/motor_fixtures.py +++ b/tests/fixtures/motor/motor_fixtures.py @@ -6,7 +6,6 @@ ## Motors and rockets - @pytest.fixture def cesaroni_m1670(): # old name: solid_motor """Create a simple object of the SolidMotor class to be used in the tests. @@ -141,4 +140,4 @@ def generic_motor(): dry_inertia=(0.2, 0.2, 0.08), ) - return motor \ No newline at end of file + return motor diff --git a/tests/fixtures/rockets/rocket_fixtures.py b/tests/fixtures/rockets/rocket_fixtures.py index e471e654b..3a1c82988 100644 --- a/tests/fixtures/rockets/rocket_fixtures.py +++ b/tests/fixtures/rockets/rocket_fixtures.py @@ -275,4 +275,4 @@ def dimensionless_calisto(kg, m, dimensionless_cesaroni_m1670): coordinate_system_orientation="tail_to_nose", ) example_rocket.add_motor(dimensionless_cesaroni_m1670, position=(-1.373) * m) - return example_rocket \ No newline at end of file + return example_rocket diff --git a/tests/fixtures/surfaces/surface_fixtures.py b/tests/fixtures/surfaces/surface_fixtures.py index 795c8e8bd..10595205f 100644 --- a/tests/fixtures/surfaces/surface_fixtures.py +++ b/tests/fixtures/surfaces/surface_fixtures.py @@ -76,4 +76,3 @@ def calisto_rail_buttons(): angular_position=45, name="Rail Buttons", ) - diff --git a/tests/fixtures/units/numerical_fixtures.py b/tests/fixtures/units/numerical_fixtures.py index 0b0bb0e0d..8bc6883cf 100644 --- a/tests/fixtures/units/numerical_fixtures.py +++ b/tests/fixtures/units/numerical_fixtures.py @@ -25,4 +25,4 @@ def kg(): numericalunits.kg A simple object of the numericalunits.kg class """ - return numericalunits.kg \ No newline at end of file + return numericalunits.kg