qurator-spk/setuptools_ocrd

Add tests + CI

Opened this issue · 4 comments

  • Tests
  • CI

Some basic CI functionality is there, but

  • only a dummy test for now
  • there seems to be no standard on specifying tests in pyproject (setuptools has test_suite but is it deprecated now as setup.py test seems to be deprecated?)
  • only runs on release (this is easily fixable)

Testing this is a bit tricky:

  • Build a local wheel and serve it via HTTP (serve-local-wheel.sh)
  • Have a test project and install it using pip --extra-index-url
    • How to make sure it only uses the test-built wheel, not the old one on PyPI?
  • Check that the version came from ocrd-tool.json

I found a simpler way to test this: Build a test project without build isolation, with setuptools_ocrd installed in the active virtualenv: python3 -m build --no-isolation.

Documented here https://github.com/qurator-spk/setuptools_ocrd/blob/master/README-DEV.md#without-build-isolation

I've added a test project in test_project/.