Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix broken tests by including required assets in package_data #532

Closed
wants to merge 2 commits into from

Conversation

carlthome
Copy link
Contributor

Working on packaging madmom in nixpkgs (WIP here) and noticed that specific tests failed when testing the installed (non-editable) package by:

MCVE

git clone https://github.com/CPJKU/madmom.git
cd madmom

git submodule init
git submodule update

python -m venv .venv
source .venv/bin/activate

pip install .
pip install pytest

rm -r madmom

pytest

Output

====================================================== short test summary info ======================================================
FAILED tests/test_bin.py::TestTCNBeatTrackerProgram::test_binary - IndexError: list index out of range
FAILED tests/test_bin.py::TestTCNBeatTrackerProgram::test_run - IndexError: list index out of range
FAILED tests/test_bin.py::TestTCNTempoDetectorProgram::test_binary - IndexError: list index out of range
FAILED tests/test_bin.py::TestTCNTempoDetectorProgram::test_run - IndexError: list index out of range
FAILED tests/test_features_beats.py::TestTCNBeatProcessorClass::test_process_tcn - IndexError: list index out of range
====================================== 5 failed, 806 passed, 188 warnings in 60.53s (0:01:00) =======================================

Turns out these tests depend on static assets (2019 models) that are currently not included in package_data. This PR fixes that such that the installed package passes its tests.

@carlthome
Copy link
Contributor Author

Already fixed in #531 - closing!

@carlthome carlthome closed this Nov 28, 2023
@carlthome carlthome deleted the log-subprocess branch November 28, 2023 23:17
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.

1 participant