HomePhabricator

[electrum] fix test_runner.py failure when PyQt5 is not installed

Description

[electrum] fix test_runner.py failure when PyQt5 is not installed

Summary:
If/when we start adding tests to the electrumabc_gui package, we will need to deal with this. For now, just fix the error by filtering the results returned by unittest.defaultTestLoader.discover

One solution would be to make PyQt5 a requirement for Electrum ABC even when no GUI is needed (I doubt that there is much to test in that package that does not have a hard dependency on Qt).

Depends on D14134

Test Plan: using a virtualenv with only requirements.txt installed (not requirements-binary.txt so no PyQt5), run python electrum/test_runner.py

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D14135

Details

Provenance
PiRKAuthored on Jun 27 2023, 14:32
PiRKPushed on Jun 28 2023, 05:19
Reviewer
Restricted Project
Differential Revision
D14135: [electrum] fix test_runner.py failure when PyQt5 is not installed
Parents
rABC8f13e1b0d561: [electrum] move run_tests.py -> test_runner.py
Branches
Unknown
Tags
Unknown