Skip to content

Ml service tests#3

Merged
Sebastijan-Dominis merged 17 commits into
mainfrom
ml-service-tests
Mar 31, 2026
Merged

Ml service tests#3
Sebastijan-Dominis merged 17 commits into
mainfrom
ml-service-tests

Conversation

@Sebastijan-Dominis
Copy link
Copy Markdown
Owner

Description

This PR adds a lot of unit tests for the ml_service/ code - unit tests cover over 99% of lines and 96% of branches.

It also adds more integration and e2e tests for proper coverage.

Finally, it improves on the existing README.md in a meaningful way, and updates the documentation in general.

Type of change

  • feature
  • fix
  • docs

Checklist

  • Tests added or updated
  • Tests passing
  • Documentation updated if needed
  • CI checks pass

Added a lot of tests covering ml_service - both frontend and backend.
Ran coverage and got ~70% for now. Updated .gitignore to ignore the
tools directory, which just contains the coverage report. Fixed one mypy
issue in tests that occurred as a result of two conftest.py files being
present in tests/. More tests will be added, but this is a good start.
Fixed a few dozen mypy issues that existed in tests, and added the tests
directory to the mypy pre-commit hook and ruff configuration.
Added mypy checks for scripts, and fixed two issues that were discovered
when running mypy on the scripts for the first time.
Improved the nesting of tests to better reflect the structure of the
codebase, and added more tests to increase coverage and ensure
robustness.
Added more tests for the ml_service directory, and increased coverage to
over 80%.
Increased the tests coverage of ml_service to 90%, and started tracking
it in the CI. Added a line to .gitignore to ignore the coverage report
xml file for ml_service.
Added more tests for the ml_service code, greatly increasing the
coverage. Structured the files more logically, so they roughly mirror
the structure of the ml_service code itself.
Added more tests to ml_service, which now has >99% code coverage.
This should help ensure the reliability and robustness of the service
as we continue to develop and maintain it.
While we already had a handful of integration and e2e tests, we needed
more. This commit adds a few more.
The integration and e2e tests were not properly nested earlier. This
commit fixes that. It also adds some more integration tests.
Added more integration tests, focusing on pipelines.
Added more integration tests and improved the file structure for better
organization.
Integration tests now cover over 52% of the lines.
Clarified what the tests are really testing. Improved the main README.md.
Corrected a few typos in the other documents. Removed one unnecessary
line from pytest.ini.
The tests were failing in the CI, and the instruction says that httpx is
required for testing. I added the installation of httpx in the tests.yml
CI workflow file.
@Sebastijan-Dominis Sebastijan-Dominis merged commit 7c45369 into main Mar 31, 2026
2 checks passed
@Sebastijan-Dominis Sebastijan-Dominis deleted the ml-service-tests branch March 31, 2026 07:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant