Page MenuHomeSoftware Heritage

tests: migrate to pytest
ClosedPublic

Authored by douardda on Oct 25 2018, 1:40 PM.

Details

Reviewers
ardumont
Group Reviewers
Reviewers
Summary

related to T1261.

Also add a tox file

related to T1247.

Test Plan

pytest should pass (via pifpaf if no pg is running)
but for now I have a few tests that fail (test_origin_metadata.py)

Diff Detail

Repository
rDCIDX Metadata indexer
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 1905
Build 2292: arc lint + arc unit

Event Timeline

ardumont added a subscriber: ardumont.
ardumont added inline comments.
pytest.ini
3

Why django?
The swh-indexer does not use django (only swh-deposit and swh-web do ;)

requirements-test.txt
2

same.

This revision now requires changes to proceed.Oct 25 2018, 1:58 PM
pytest.ini
3

because without it, I have most of the tests that fail with django.core.exceptions.ImproperlyConfigured errors

douardda added inline comments.
pytest.ini
3

forget it, don't know what I did, but I messed up

pytest.ini
3

is it possible you:

  • copied from swh-deposit that pytest.ini?
  • t run tox ~> it then complained about django.
  • then you added the pytest-django to make it happy ;)

?

douardda marked an inline comment as done.

rebase and address silly my django stuff

This revision is now accepted and ready to land.Oct 25 2018, 4:03 PM