Skip to content

tests: rename test classes so pytest collects them - #577

Merged
tompollard merged 1 commit into
MIT-LCP:mainfrom
ehanrsha:fix/test-processing-collection
Oct 27, 2026
Merged

tompollard merged 1 commit into
MIT-LCP:mainfrom
ehanrsha:fix/test-processing-collection

Conversation

@ehanrsha

Copy link
Copy Markdown
Contributor

Running pytest tests/test_processing.py -v prints collected 0 items, even though the file contains 8 test methods.

Cause: the classes are named test_processing and test_qrs. pytest's default python_classes = "Test*" only collects classes whose names start with Test (unless they subclass unittest.TestCase, which these don't). So the whole file is silently skipped, both locally and in CI. That means the resampling, peak-finding, GQRS, and XQRS tests have not been running.

Fix: rename the classes to TestProcessing and TestQrs. No test logic changed.

Before:

pytest tests/test_processing.py -v
collected 0 items

After:

pytest tests/test_processing.py -v
collected 8 items
8 passed in 4.27s

Tested on Windows 11, Python 3.14.3, pytest 9.1.1.

@tompollard tompollard left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ehanrsha!

@tompollard
tompollard merged commit 73b93b6 into MIT-LCP:main Oct 27, 2026
13 of 19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants