- Sort Score
- Num 10 results
- Language All
Results 1 - 1 of 1 for dump_python (0.05 seconds)
-
tests/test_arbitrary_types.py
] class MyModel(BaseModel): model_config = ConfigDict(arbitrary_types_allowed=True) custom_field: FakeNumpyArrayPydantic ta = TypeAdapter(MyModel) assert ta.dump_python(MyModel(custom_field=FakeNumpyArray())) == { "custom_field": [1.0, 2.0, 3.0] } assert ta.json_schema() == snapshot( { "properties": { "custom_field": {Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Dec 20 15:55:38 GMT 2025 - 3.8K bytes - Click Count (0)