()
| 16 | |
| 17 | |
| 18 | def test_parse_obj_as_model(): |
| 19 | class Model(BaseModel): |
| 20 | x: int |
| 21 | y: bool |
| 22 | z: str |
| 23 | |
| 24 | model_inputs = {'x': '1', 'y': 'true', 'z': 'abc'} |
| 25 | assert parse_obj_as(Model, model_inputs) == Model(**model_inputs) |
| 26 | |
| 27 | |
| 28 | def test_parse_obj_preserves_subclasses(): |
nothing calls this directly
no test coverage detected