TLDR Web Dev · ARTICLES & TUTORIALS

HOW I WRITE TESTS IN GO

blog.verygoodsoftwarenotvirus.ru14 min read

Summary from the TLDR Web Dev newsletter

Golang comes with its own testing library, which is not common among popular programming languages. Unit tests in Go should be written to run in parallel by default so that concurrency issues are surfaced early on. The testing package has a comprehensive set of flags and can provide code coverage reports, race condition detection, static analysis, shuffled test execution, and more.