haddocking / arctic3d

Automatic Retrieval and ClusTering of Interfaces in Complexes from 3D structural information
Apache License 2.0
27 stars 6 forks source link

Refactor tests that depend on API calls #418

Closed rvhonorato closed 5 months ago

rvhonorato commented 5 months ago

The results of some of the current tests can be affected by unwanted artifacts since they are also acting as sanity tests for the API endpoints, see https://github.com/haddocking/arctic3d/actions/runs/8892529851/job/24416781299?pr=407

For example the test below will fail if the response from the API changes:

https://github.com/haddocking/arctic3d/blob/7082f8586693c93b09a4d7e2f1b1b7b33c0e33de/tests/test_interface.py#L124-L142

This can be fixed by adding a sanity test screening to the endpoints;

And mocking their response in the unit-tests