ActivityPub integration tests and Django

Fyi I contributed some weeks ago to add tests on a Django + DRF + Tastypie application. The goal was (but not limited to) to discover the application behavior. I tried to make some efforts to rationalize api viewset testing with pytest, using class based tests. It is a bit immature but did the job.

See e.g. https://github.com/Fresnoy/kart/blob/master/production/tests/test_api_v2.py to see CBT in action and https://github.com/Fresnoy/kart/blob/master/utils/tests/utils.py for the code.

It may gives some ideas. I am not expert in API testing but I didn’t seen this elsewhere.

1 Like