Repository: manchenkoff/openapi3-parser (language: python)

Issue:
[BUG] Parser doesnt support Text/Json nor application/*+json as valid types for content within request body
**Describe the bug**
When the Open API specification contains context with text/json or application/*+json these are not recognized as valid types. 

**To Reproduce**
Steps to reproduce the behavior:
1. Load a api specification containing any of these types in the request body content:
```JSON "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/..."
                            }
                        },
                        "text/json": {
                            "schema": {
                                "$ref": "#/components/schemas/..."
                            }
                        },
                        "application/*+json": {
                            "schema": {
                                "$ref": "#/components/schemas/..."
                            }
                        }
                    }
                }
```
2. Pass this file to the openapi parser
3. See error

**Expected behavior**
These types should be valid tpes and the specification file should be validated.

**System details (please complete the following information):**
 - Windows 11
 - OpenAPI / Swagger version OpenAPI 
 - Python version 3.9
 
**Additional context**
Removing these entries from the file allowed the validaation and loading of the ile into python.



Discussion / hints:

Fix patch:
diff --git a/src/openapi_parser/enumeration.py b/src/openapi_parser/enumeration.py
index d444e12..2660516 100644
--- a/src/openapi_parser/enumeration.py
+++ b/src/openapi_parser/enumeration.py
@@ -97,6 +97,8 @@ class CookieParameterStyle(Enum):
 @unique
 class ContentType(Enum):
     JSON = 'application/json'
+    JSON_TEXT = 'text/json'
+    JSON_ANY = 'application/*+json'
     XML = 'application/xml'
     FORM = 'application/x-www-form-urlencoded'
     MULTIPART_FORM = 'multipart/form-data'


Test patch:
diff --git a/tests/builders/test_content_builder.py b/tests/builders/test_content_builder.py
index 7043674..58b0f46 100644
--- a/tests/builders/test_content_builder.py
+++ b/tests/builders/test_content_builder.py
@@ -31,6 +31,19 @@ def _get_schema_factory_mock(expected_value: Schema) -> SchemaFactory:
         ],
         _get_schema_factory_mock(string_schema)
     ),
+    (
+        {
+            "text/json": {
+                "schema": {
+                    "type": "string"
+                }
+            }
+        },
+        [
+            Content(type=ContentType.JSON_TEXT, schema=string_schema)
+        ],
+        _get_schema_factory_mock(string_schema)
+    ),
 )
 
 
diff --git a/tests/test_enumeration.py b/tests/test_enumeration.py
index b4ae5b4..ebf1f8c 100644
--- a/tests/test_enumeration.py
+++ b/tests/test_enumeration.py
@@ -139,6 +139,8 @@ def test_parameter_location_error() -> None:
 
 media_type_provider = (
     ("application/json", ContentType.JSON),
+    ("application/*+json", ContentType.JSON_ANY),
+    ("text/json", ContentType.JSON_TEXT),
     ("application/xml", ContentType.XML),
     ("application/x-www-form-urlencoded", ContentType.FORM),
     ("multipart/form-data", ContentType.MULTIPART_FORM),