tests.py: fix lint warnings