Thoughts on MTP providing source generation of tests #5714
thompson-tomo
started this conversation in
Ideas
Replies: 1 comment 11 replies
-
Thanks for opening this discussion @thompson-tomo It's up to the test frameworks to use source generators (there is nothing to do on MTP side). For example, TUnit already uses source gen approach. Also, MSTest.Engine is using source gen, though it's not in complete feature parity with the reflection-based MSTest yet. One problem with using source gen is that it supports C#/VB only. So, frameworks that want to support F# will still have to implement a reflection-based fallback for F#. |
Beta Was this translation helpful? Give feedback.
11 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Has there been any thought/discussion surrounding if MTP should provide a source generator for test cases & the corresponding attributes?
What I am thinking is a user decorates their test class with attributes describing the arguments or parameters and based on that it generates the test class which is run by the corresponding test framework. Obviously that is a simplistic view but it can be extended.
I like this idea as it is equivalent to what has occurred with logging where a user can seamlessly switch between framework NLOG, Serilog as long as it leverage MEL.
This approach would likely be a benefit to BenchmarkDotnet and others
Beta Was this translation helpful? Give feedback.
All reactions