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

Script can be run via pytest options #1

Merged
merged 8 commits into from
Feb 17, 2024
Merged

Conversation

maciej-gol
Copy link
Owner

@maciej-gol maciej-gol commented Feb 17, 2024

A number of options are autodiscovered in this approach, allowing simpler UX.

Comparison:

$ pytest-bisect-tests \
    --failing-test "integration_data/test_groups_test.py::test_failing_group2" \
    --collect-options "--test-group-count 2 --test-group 2" \
    --run-options "test_groups_test.py"

vs

$ pytest --bisect-first-failure --test-group-count 2 --test-group 2 test_groups_test.py

In the new UX, only the --bisect-first-failure argument is needed. All the other info is picked from the pytest's cache.

@maciej-gol maciej-gol changed the title run tests Script can be run via pytest options Feb 17, 2024
@maciej-gol maciej-gol merged commit 63be7c4 into main Feb 17, 2024
1 check passed
@maciej-gol maciej-gol deleted the pytest-cmdline-switch branch February 17, 2024 21:18
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