VerifyTests / Verify

Verify is a snapshot testing tool that simplifies the assertion of complex data models and documents.
MIT License
2.51k stars 141 forks source link

Show how to ignore class level params in NUnit tests #1241

Closed tom-englert closed 3 months ago

tom-englert commented 3 months ago

IgnoreParametersForVerified only works on method params, not class params.

This PR adds tests that show a workaround, using a combination of UseTypeName and DisableRequireUniquePrefix, to remove the class params from the output file name.

SimonCropp commented 3 months ago

@tom-englert yeah that is a poor implementation on my part. you should not need to hack around it

thoughts on this as a better fix https://github.com/VerifyTests/Verify/pull/1249 ?

tom-englert commented 3 months ago

This workaround was fine for my simple use case, however #1249 would be more comprehensive.

SimonCropp commented 3 months ago

deploying v26 now