Skip to content

Conversation

@egrace479
Copy link
Member

@egrace479 egrace479 commented Jul 25, 2024

Set up automated testing for the repo.

This brings up a challenge: not all hash functions are guaranteed--options are based on the user's system.

We may want to revamp that part of the test to check for system available hash functions and test those, but note if hashes are not covered based on the system?

Add automated test workflow for PRs and push
@egrace479 egrace479 added the enhancement New feature or request label Jul 25, 2024
@egrace479 egrace479 requested a review from thompsonmj July 25, 2024 18:24
@egrace479 egrace479 marked this pull request as draft July 25, 2024 18:25
use python 3.12
@egrace479 egrace479 added the question Further information is requested label Jul 25, 2024
@egrace479 egrace479 marked this pull request as ready for review July 26, 2024 19:59
@egrace479
Copy link
Member Author

@thompsonmj, I got it working with your suggestion. Unfortunately, adding a print statement on what isn't run was not as easy, so we should add a note to the README about it (I'd say after your update in PR #16).

@egrace479
Copy link
Member Author

@thompsonmj, I got it working with your suggestion. Unfortunately, adding a print statement on what isn't run was not as easy, so we should add a note to the README about it (I'd say after your update in PR #16).

Going to just merge update in #16 first, then the auto testing will work since it'll be scoped to the hashes available on the system.

@egrace479
Copy link
Member Author

@thompsonmj, I pulled in your updates and now it seems to be working. I also added -rs after pytest so it will print skipped:

============================= test session starts ==============================
platform linux -- Python 3.[12](https://github.com/Imageomics/sum-buddy/actions/runs/10147680506/job/28058648529?pr=15#step:6:13).4, pytest-8.3.2, pluggy-1.5.0
rootdir: /home/runner/work/sum-buddy/sum-buddy
configfile: pyproject.toml
collected 66 items

tests/test_filter.py .............                                       [ 19%]
tests/test_getChecksums.py .......                                       [ 30%]
tests/test_hasher.py ..............s..................sssss....          [ 93%]
tests/test_mapper.py ....                                                [100%]

=========================== short test summary info ============================
SKIPPED [2] tests/test_hasher.py:54: ripemd[16](https://github.com/Imageomics/sum-buddy/actions/runs/10147680506/job/28058648529?pr=15#step:6:17)0 not available on system and not guaranteed.
SKIPPED [1] tests/test_hasher.py:54: sha512_256 not available on system and not guaranteed.
SKIPPED [1] tests/test_hasher.py:54: sm3 not available on system and not guaranteed.
SKIPPED [1] tests/test_hasher.py:54: sha512_[22](https://github.com/Imageomics/sum-buddy/actions/runs/10147680506/job/28058648529?pr=15#step:6:23)4 not available on system and not guaranteed.
SKIPPED [1] tests/test_hasher.py:54: md5-sha1 not available on system and not guaranteed.
======================== 60 passed, 6 skipped in 0.29s =========================

@egrace479 egrace479 merged commit 9da8f67 into main Jul 29, 2024
@egrace479 egrace479 deleted the auto-test branch July 29, 2024 18:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request question Further information is requested

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants