First, you need to install the dependencies:
pip3 install pytestThen, make sure that the server is running and that you can access it.
Then, you can run the tests with the following command:
cd tests
pytestThe tests will try to test the different algorithms provided by the service by looking at their inputs and outputs and by trying to run them with fake data.
Those tests are not exhaustive and are only here to help you to make sure that your service is compliant with the Algo API spec.
The tests won't be able to test the real behavior of your algorithms, they will only test the inputs and outputs of your algorithms.
If you want to add specific tests for an algorithm, you can create a new file in the algorithms_specific_tests directory with the following name and add it to the ALGORITHMS_SPECIFIC_TESTS dictionary in the test_algo_api_compliance.py file.
from algorithms_specific_tests import objectDetectionMetricsTests
ALGORITHMS_SPECIFIC_TESTS = {
"ObjectsDetectionMetrics": objectDetectionMetricsTests.test_object_detection_metrics_algorithm
}