From 7c31423d62f119b8a628c732aa719f214194c2fa Mon Sep 17 00:00:00 2001 From: Lvyshnevska Date: Sun, 23 Jun 2024 15:17:15 +0200 Subject: [PATCH] search tests updated --- BackEnd/search/tests/test_advanced_search.py | 2 + .../tests/test_search_by_name_region.py | 58 +++++++++++++++++++ 2 files changed, 60 insertions(+) diff --git a/BackEnd/search/tests/test_advanced_search.py b/BackEnd/search/tests/test_advanced_search.py index 00200c218..0014ada1e 100644 --- a/BackEnd/search/tests/test_advanced_search.py +++ b/BackEnd/search/tests/test_advanced_search.py @@ -139,6 +139,8 @@ def test_advanced_search_serializer_fields(self): "product_info": "fruits from Dnipro", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kyiv.person_id, } ] diff --git a/BackEnd/search/tests/test_search_by_name_region.py b/BackEnd/search/tests/test_search_by_name_region.py index 927e61f21..b279afff2 100644 --- a/BackEnd/search/tests/test_search_by_name_region.py +++ b/BackEnd/search/tests/test_search_by_name_region.py @@ -63,6 +63,8 @@ def test_get_profile_filtered_by_region_eng_unauthorized(self): "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, } @@ -92,6 +94,8 @@ def test_get_profile_filtered_by_region_eng_authorized(self): "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, } @@ -121,6 +125,8 @@ def test_get_profile_filtered_by_region_ukr_authorized(self): "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, } @@ -149,6 +155,8 @@ def test_get_profile_filtered_by_region_ukr_unauthorized(self): "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, } @@ -178,6 +186,8 @@ def test_get_profile_filtered_by_region_ukr_partial_authorized(self): "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, } @@ -206,6 +216,8 @@ def test_get_profile_filtered_by_region_ukr_partial_unauthorized(self): "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, } @@ -235,6 +247,8 @@ def test_get_profile_filtered_by_region_ukr_lower_case_authorized(self): "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, } @@ -290,6 +304,8 @@ def test_get_profile_filtered_by_name_authorized(self): "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, } @@ -344,6 +360,8 @@ def test_get_profile_filtered_by_name_and_region_eng_unauthorized(self): "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, } @@ -375,6 +393,8 @@ def test_get_profile_filtered_by_name_and_region_eng_authorized(self): "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, } @@ -474,6 +494,8 @@ def test_get_profile_filtered_by_name_partially_authorized(self): "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, } @@ -502,6 +524,8 @@ def test_get_profile_filtered_by_name_partially_unauthorized(self): "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, } @@ -535,6 +559,8 @@ def test_get_profile_filtered_by_name_and_region_eng_partialyy_authorized( "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, } @@ -572,6 +598,8 @@ def test_get_profile_ordered_by_name_asc_unauthorized( "regions_ukr_display": "Харків", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_charkiv.person_id, "is_saved": False, }, @@ -590,6 +618,8 @@ def test_get_profile_ordered_by_name_asc_unauthorized( "regions_ukr_display": "Чернігів", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_chernigiv.person_id, "is_saved": False, }, @@ -608,6 +638,8 @@ def test_get_profile_ordered_by_name_asc_unauthorized( "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, }, @@ -626,6 +658,8 @@ def test_get_profile_ordered_by_name_asc_unauthorized( "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, }, @@ -656,6 +690,8 @@ def test_get_profile_ordered_by_name_asc_authorized( "regions_ukr_display": "Харків", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_charkiv.person_id, "is_saved": False, }, @@ -674,6 +710,8 @@ def test_get_profile_ordered_by_name_asc_authorized( "regions_ukr_display": "Чернігів", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_chernigiv.person_id, "is_saved": False, }, @@ -692,6 +730,8 @@ def test_get_profile_ordered_by_name_asc_authorized( "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, }, @@ -710,6 +750,8 @@ def test_get_profile_ordered_by_name_asc_authorized( "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, }, @@ -739,6 +781,8 @@ def test_get_profile_ordered_by_name_dsc_unauthorized( "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, }, @@ -757,6 +801,8 @@ def test_get_profile_ordered_by_name_dsc_unauthorized( "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, }, @@ -775,6 +821,8 @@ def test_get_profile_ordered_by_name_dsc_unauthorized( "regions_ukr_display": "Чернігів", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_chernigiv.person_id, "is_saved": False, }, @@ -793,6 +841,8 @@ def test_get_profile_ordered_by_name_dsc_unauthorized( "regions_ukr_display": "Харків", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_charkiv.person_id, "is_saved": False, }, @@ -823,6 +873,8 @@ def test_get_profile_ordered_by_name_dsc_authorized( "regions_ukr_display": "Київ", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_kiev.person_id, "is_saved": False, }, @@ -841,6 +893,8 @@ def test_get_profile_ordered_by_name_dsc_authorized( "regions_ukr_display": "Дніпро", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_dnipro.person_id, "is_saved": False, }, @@ -859,6 +913,8 @@ def test_get_profile_ordered_by_name_dsc_authorized( "regions_ukr_display": "Чернігів", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_chernigiv.person_id, "is_saved": False, }, @@ -877,6 +933,8 @@ def test_get_profile_ordered_by_name_dsc_authorized( "regions_ukr_display": "Харків", "founded": 2022, "address": "Test Country, Test City, St. Test, 1", + "banner": None, + "logo": None, "person": self.company_charkiv.person_id, "is_saved": False, },