-
-
Couldn't load subscription status.
- Fork 1k
Allow ArgumentsSource to reference methods in other types #2748
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
Allow ArgumentsSource to reference methods in other types #2748
Conversation
|
Maybe do the same thing for |
|
Makes sense. Pushed! |
|
Can you also please add or update integration tests? |
|
I'm having trouble grokking the tests in this repo. I could use some help. Where would be the appropriate place for the new/modified tests? I can't find any existing tests that involve |
|
Thanks very much. Added two new tests to verify the newly-added behavior. All tests are passing locally. Edit: and I see they're also passing on the CI, nice |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JimmyCushnie!
Implements #2744
I added a new constructor for
ArgumentsSourceAttributewhich takes a custom type. I implemented the logic inBenchmarkConverterso that the custom type can be used. The behavior of the existing constructor is preserved.I updated the docs to explain the new feature.
I renamed a few internal method parameters for clarity.
This is my first contribution to BenchmarkDotNet. Please let me know if I did anything wrong!