-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
addcall does not allow binding of keyword args in parametrized test #42
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
Comments
Original comment by Anonymous: It is frequent for data driven tests to have a few mandatory parameters and some optional parameters. Keyword parameters provide a convenient way to provide default value for optional parameters. This makes it easy to add a new optional parameter to handle the need of a few new specific test without impacting existing tests. I currently work around this by forwarding to a nested function as in the example below. dbo_class is the only required parameters, though the code below does not express this. {{{ def test_meta_dbo( data ): }}} |
Originally reported by: BitBucket: blep, GitHub: blep
When calling metafunc.addcall in pytest_generate_tests and providing keyword args with default value, addcall fails with a message such as:
Code example to reproduce the issue:
The text was updated successfully, but these errors were encountered: