-
-
Notifications
You must be signed in to change notification settings - Fork 836
Closed
Description
pytest is way superior (and also more comfortable) compared to unittest.
less work to write tests, prettier / easier readable tests, more useful output (esp. on failure).
the existing tests can be taken "as is" as a starting point, pytest is able to run them.
later, more pytest specific features can be used to further improve.
be careful!
borg.selftest is special because it must not depend on pytest. it runs every time borg is invoked by a user.
see there: #6157 (comment)
These must not be converted to unittest:
from .testsuite.hashindex import HashIndexDataTestCase, HashIndexRefcountingTestCase, HashIndexTestCase
from .testsuite.crypto import CryptoTestCase
from .testsuite.chunker import ChunkerTestCase
SELFTEST_CASES = [
HashIndexDataTestCase,
HashIndexRefcountingTestCase,
HashIndexTestCase,
CryptoTestCase,
ChunkerTestCase,
]
Reactions are currently unavailable