From eaaa46117a437ea98079fe9cc7da49f492d1caac Mon Sep 17 00:00:00 2001 From: Sina Atalay Date: Fri, 17 May 2024 14:30:26 +0300 Subject: [PATCH] tests: update data_models tests --- tests/test_data_models.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_data_models.py b/tests/test_data_models.py index bddcacf..d4c0f96 100644 --- a/tests/test_data_models.py +++ b/tests/test_data_models.py @@ -296,6 +296,7 @@ def test_if_the_schema_is_the_latest(root_directory_path): (None, None, None, "", "", ""), (None, "2020-01-01", None, "Jan. 2020", "2020", ""), (None, "present", None, "Jan. 2024", "2024", ""), + ("2002", "2020", "2024", "2024", "2024", ""), ], ) @time_machine.travel("2024-01-01") @@ -328,7 +329,7 @@ def test_publication_dates(publication_entry, date, expected_date_string): assert publication_entry.date_string == expected_date_string -@pytest.mark.parametrize("date", ["aaa", None, "2025-23-23"]) +@pytest.mark.parametrize("date", ["2025-23-23"]) def test_invalid_publication_dates(publication_entry, date): with pytest.raises(pydantic.ValidationError): publication_entry["date"] = date