go-approval-tests
go-approval-tests copied to clipboard
Feature request - allow overriding of filename
Currently, the files are named after the executed test.
However, if you want to run multiple approvals in a single test (for example, with a table driven test) then the different approvals will overwrite each other.
It would be nice to have a function like-
func VerifyWithFilename(t Failable, reader io.Reader, filename string)
which overrides the default naming behaviour.
I think this can be easily added, I will work on a PR for it soon