99
1010LIST_URL = reverse ("v1:admin-shop-category-list" )
1111CHOICES_URL = LIST_URL + "choices/"
12- JSON_SCHEMA_URL = LIST_URL + "json-schema/"
1312
1413
1514@pytest .fixture
@@ -63,16 +62,6 @@ def test_category_choices_include_meta_for_event(api_client, category_fixtures):
6362 assert event_meta ["started_at" ] == "2026-08-01"
6463
6564
66- @pytest .mark .django_db
67- def test_category_json_schema_exposes_choice_meta_schema (api_client , category_fixtures ):
68- response = api_client .get (JSON_SCHEMA_URL )
69- assert response .status_code == HTTP_200_OK
70- ui_schema = response .json ()["ui_schema" ]
71- meta_schema = ui_schema ["event" ]["ui:options" ]["choiceMetaSchema" ]
72- assert meta_schema ["organization" ]["label" ] == "조직"
73- assert ui_schema ["group" ]["ui:options" ]["choiceMetaSchema" ]["priority" ]["label" ] == "순서"
74-
75-
7665@pytest .mark .django_db
7766def test_category_choices_include_audit_meta_for_event (api_client , category_fixtures ):
7867 # BaseAbstractModel 의 audit 메타(created_by/updated_by/created_at/updated_at)가 자동으로 붙어야 한다.
@@ -84,15 +73,6 @@ def test_category_choices_include_audit_meta_for_event(api_client, category_fixt
8473 assert event_meta ["created_at" ] is not None
8574
8675
87- @pytest .mark .django_db
88- def test_category_json_schema_exposes_audit_meta_schema (api_client , category_fixtures ):
89- response = api_client .get (JSON_SCHEMA_URL )
90- assert response .status_code == HTTP_200_OK
91- meta_schema = response .json ()["ui_schema" ]["event" ]["ui:options" ]["choiceMetaSchema" ]
92- assert meta_schema ["created_by" ]["label" ] == "생성자"
93- assert {"created_by" , "updated_by" , "created_at" , "updated_at" } <= set (meta_schema )
94-
95-
9676@pytest .mark .django_db
9777def test_category_filter_by_group (api_client , category_fixtures ):
9878 response = api_client .get (LIST_URL , {"group" : str (category_fixtures ["g2026" ].id )})
0 commit comments