Enforce parameter names in steps questionAnswered
Is it possible on a project level to enforce parameter naming conventions in steps? For example take this step:
I perform a simple search on '(.*)'"
Is there a way to globally enforce a rule where, for example, the matching parameter is not allowed to contain a question mark or quote or the letter q or something else?
Yes, I know you can use regexes in the parameters but I want to enforce a global rule that will throw some kind of error if I use illegal characters in the parameter name.
Thank you in advance!
Hi Steven Hansen,
I have moved this post to it's correct location under general discussions.
I am wondering if you could user step argument transformations to check the parameter for your unwanted chars and throw an exception if they exist.
otherwise I think your only other solution is to use c#10 and constant interpolated strings to create a regex pattern that matches what you need and then can be re-usable across the project, only usable with .NET 6 I believe so might not be an option.0
Please sign in to leave a comment.