-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Add a deselected parameter to assert_outcomes() #9113
Copy link
Copy link
Closed
Labels
good first issueeasy issue that is friendly to new contributoreasy issue that is friendly to new contributortype: proposalproposal for a new feature, often to gather opinions or design the API around the new featureproposal for a new feature, often to gather opinions or design the API around the new feature
Metadata
Metadata
Assignees
Labels
good first issueeasy issue that is friendly to new contributoreasy issue that is friendly to new contributortype: proposalproposal for a new feature, often to gather opinions or design the API around the new featureproposal for a new feature, often to gather opinions or design the API around the new feature
What's the problem this feature will solve?
I'd like to be able to use
pytester.RunResult.assert_outcomes()to check deselected count.Describe the solution you'd like
Add a
deselectedparameter topytester.RunResult.assert_outcomes()Plugins that use
pytest_collection_modifyitemsto change theitemsand add change the deselected items need to be tested. Usingassert_outcomes()to check the deselected count would be helpful.Alternative Solutions
Use
parseoutcomes()instead ofassert_outcomes().parseoutcomes()returns a dictionary that includesdeselected, if there are any.However, if we have a series of tests, some that care about deselected, and some that don't, then we may have some tests using
assert_outcomes()and some usingparseoutcomes(), which is slightly annoying.Additional context