docs: Correct schema parsing for JSONField by beruic · Pull Request #5878 · encode/django-rest-framework (original) (raw)
Well, I would like to, but this is new ground for me, time is sparse, and i already spend a lot of time tracking this down. I have tested this informally, and now I have looked at how to write a test for this for about an hour, and I cannot figure out how to test this.
Perhaps there should just be made an issue to test rest_framework.schemas.inspectors.field_to_schema()
by it self? This of course means that all the other fields should be tested, but then again, it feels kinda stupid to do. It really any value. I think it would be valuable if you could test the docs-generated HTML for each field, but that is still way beyond my scope of understanding of DRF.
Perhaps it would make sens to make it a part of some test of rest_framework.schemas.inspectors.AutoSchema
, but again that is beyond my scope.
If it really is the case that none of the other output of rest_framework.schemas.inspectors.field_to_schema()
is tested, I think this should just be merged, and an issue should be created to figure out how to test.
All in all I think this is a bigger task, but perhaps you are wiser @carltongibson?