From fdc1ef09b8c8efbdf204c35174264d48de2c0321 Mon Sep 17 00:00:00 2001 From: Mladen Gibanica <11275336+mgcth@users.noreply.github.com> Date: Sun, 5 May 2024 07:44:53 +0200 Subject: [PATCH] Update metobs data test for period=None --- tests/unit/test_unit_metobs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/unit/test_unit_metobs.py b/tests/unit/test_unit_metobs.py index ac6189d..2e633ff 100644 --- a/tests/unit/test_unit_metobs.py +++ b/tests/unit/test_unit_metobs.py @@ -477,7 +477,7 @@ class TestUnitData: @pytest.mark.parametrize( "period, data_type", [ - (None, "yaml"), + ("latest", "yaml"), (None, "json"), ("latest", "json"), ("corrected-archive", "json"), @@ -509,7 +509,7 @@ def test_unit_data_init( Data(mock_periods, period, data_type) return None - if period is not None and period not in METOBS_AVAILABLE_PERIODS: + if period not in METOBS_AVAILABLE_PERIODS and period is not None: with pytest.raises(NotImplementedError): Data(mock_periods, period, data_type) return None