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

Parametrize test_espsecure.py to enable skipping unsupported signing methods (ESPTOOL-928) #1013

Open
befeleme opened this issue Sep 25, 2024 · 1 comment

Comments

@befeleme
Copy link
Contributor

Operating System

Fedora Linux

Esptool Version

4.8.0

Python Version

Python 3.13.0~rc2

Full Esptool Command Line that Was Run

pytest -m host_test

Esptool Output

No response

What is the Expected Behaviour?

I want to run as much of the esptool test suite when building it for Fedora Linux, to make sure it works as expected.
ecdsa192 is not supported by openSSL in Fedora Linux, hence all the tests that operate on the key fail.
As tests are not parametrized, but rather loop over lists in the test bodies, I can't easily skip the ones I don't want to run.
Would it be possible to parametrize the tests, e.g. with the pytest @pytest.mark.parametrize decorator?

More Information

No response

Other Steps to Reproduce

No response

@github-actions github-actions bot changed the title Parametrize test_espsecure.py to enable skipping unsupported signing methods Parametrize test_espsecure.py to enable skipping unsupported signing methods (ESPTOOL-928) Sep 25, 2024
@radimkarnis
Copy link
Collaborator

Hello @befeleme,

if you want to skip certain tests, you can use the -k option of pytest to select and deselect tests based on their name.

Parametrizing the tests could be a solution, but how do we decide which criteria to parameterize? Another user could later come and say that some tests can't run on his machine because of another reason.

Do you think only the schemes ("rsa3072", "ecdsa192", "ecdsa256", "ecdsa384") should be parametrized?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants