-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Markers as functions #277
Labels
type: enhancement
new feature or API change, should be merged into features branch
Comments
pytestbot
added
the
type: enhancement
new feature or API change, should be merged into features branch
label
Jun 15, 2015
pytestbot
pushed a commit
that referenced
this issue
Jun 15, 2015
This removes the drone.io badge from the README as it doesn't make sense to have it on the cheeseshop status page. Fixes issue #726.
12 tasks
closing as the patch still is not provided |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Originally reported by: Alexander Steinert (BitBucket: stony8, GitHub: stony8)
Scattering a custom marker registration/defintion/usage to different
hook functions -- like done in
http://pytest.org/latest/example/markers.html#custom-marker-and-command-line-option-to-control-test-runs --
does not scale well to multiple markers.
I would prefer to define a custom marker as a function that gets called at
collection time for each marked test. Example:
With the decorator pytest.marker we could avoid calling
config.addinivalue_line("markers", ...) and be able to check marker arguments.
The arguments should be available in hooks, e.g.
Holger has an unfinished patch which allows roughly the above. His decorator is
called pytest.markdefinition. I would prefer pytest.marker but thats just a
matter of taste.
The text was updated successfully, but these errors were encountered: