5 ms·
A huge time-saver for me when adding table-driven test boilerplate in Go has been using gotests[0] to generate the template. If you use VSCode with the Go exte
by devjam 3y ago
A huge time-saver for me when adding table-driven test boilerplate in Go has been using gotests[0] to generate the template.
If you use VSCode with the Go extension it's already available there as a command "Go: Generate Unit Tests for Function/Package".
[0] https://github.com/cweill/gotests https://github.com/cweill/gotests
- kevinsundar 3y agoI just ask ChatGPT to do it. Actually just today I asked it to format an existing set of tests into table-driven format. Worked great.