Skip to content

Avoid parametrizing tests with itertools.product() #18110

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

Open
1 of 10 tasks
eerovaher opened this issue May 8, 2025 · 5 comments
Open
1 of 10 tasks

Avoid parametrizing tests with itertools.product() #18110

eerovaher opened this issue May 8, 2025 · 5 comments
Labels
good first issue Issues that are well-suited for new contributors Package-novice testing

Comments

@eerovaher
Copy link
Member

eerovaher commented May 8, 2025

There are some parametrized tests that use itertools.product() for generating parametrizations. However, in many cases they could instead use stacked @pytest.mark.parametrize() decorators, which can often be written down using fewer lines and might remove the need to import itertools in the test file.

#18109 is an example of what a pull request addressing this issue might look like.

List of files to update

It might be a good idea to update one sub-package per pull request.

@eerovaher eerovaher added testing Package-novice good first issue Issues that are well-suited for new contributors labels May 8, 2025
@jsdingra11
Copy link

Hi @eerovaher can I help into this, I looked into the issue and the #18109 and I understood how to fix that all!

@jsdingra11
Copy link

jsdingra11 commented May 13, 2025

kindly have a look : #18142

@jch1013
Copy link
Contributor

jch1013 commented May 13, 2025

hi @jsdingra11,
Saw you were working on this - is it ok if I work on the pull request for the last file in the list (astropy/wcs/wcsapi/tests/test_fitswcs.py)? I'm just starting out and there aren't other recent good first issues available. Wanted to check in to see if you've already updated this. thanks for considering!

@jsdingra11
Copy link

jsdingra11 commented May 14, 2025

hi @jsdingra11, Saw you were working on this - is it ok if I work on the pull request for the last file in the list (astropy/wcs/wcsapi/tests/test_fitswcs.py)? I'm just starting out and there aren't other recent good first issues available. Wanted to check in to see if you've already updated this. thanks for considering!

Hi @jch1013,
why not, if you are eager to help why not! I have made a pull request for the first file, lets see if it get approved, then we can do the work 50-50 for this issue!

@jch1013
Copy link
Contributor

jch1013 commented May 15, 2025

hi @jsdingra11, Saw you were working on this - is it ok if I work on the pull request for the last file in the list (astropy/wcs/wcsapi/tests/test_fitswcs.py)? I'm just starting out and there aren't other recent good first issues available. Wanted to check in to see if you've already updated this. thanks for considering!

Hi @jch1013, why not, if you are eager to help why not! I have made a pull request for the first file, lets see if it get approved, then we can do the work 50-50 for this issue!

Thanks! Appreciate it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Issues that are well-suited for new contributors Package-novice testing
Projects
None yet
Development

No branches or pull requests

3 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy