HackerTrans
TopNewTrendsCommentsPastAskShowJobs

Go test: What happens under the hood with the testing harness when you run it(matttproud.com)

3 points·by matttproud·2 ปีที่แล้ว·1 comments
matttproud.com
Go test: What happens under the hood with the testing harness when you run it

https://matttproud.com/blog/posts/go-testing-harness.html

1 comments

matttproud·2 ปีที่แล้ว
If you’re like most Go developers, you probably haven’t given much thought to what happens when you run go test in a project. You just take for granted that it works and your tests run (irrespective of whether they pass or not — though hopefully passing). But it turns out that a lot of things happen in the time between invoking go test and a single line of your tests start running. Let’s dive in and see how go test works.