File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed
Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -143,12 +143,14 @@ class SQLModelUserV2(SQLModel):
143143 )
144144
145145
146+ @pytest .mark .skipif (not VERSION .startswith ("2." ), reason = "validation_alias and serialization_alias are not supported in Pydantic v1" )
146147@pytest .mark .parametrize ("model" , [PydanticUserV2 , SQLModelUserV2 ])
147148def test_create_with_validation_alias (model : Union [Type [PydanticUserV2 ], Type [SQLModelUserV2 ]]):
148149 user = model (firstName = "John" )
149150 assert user .first_name == "John"
150151
151152
153+ @pytest .mark .skipif (not VERSION .startswith ("2." ), reason = "validation_alias and serialization_alias are not supported in Pydantic v1" )
152154@pytest .mark .parametrize ("model" , [PydanticUserV2 , SQLModelUserV2 ])
153155def test_serialize_with_serialization_alias (
154156 model : Union [Type [PydanticUserV2 ], Type [SQLModelUserV2 ]]
You can’t perform that action at this time.
0 commit comments