-
Couldn't load subscription status.
- Fork 35
Closed
Labels
Milestone
Description
As mentioned in #169, as an alternative to having a testify suite which sets up all the things, we should consider making smaller, more targeted functions which use testing.F.Cleanup to clean up on test completion.
e.g.
func newMockLambdaServer(t testing.TB) *http.Server {
lambdaServer := ...
t.Cleanup(lambdaServer.Close)
return lambdaServer
}
func newMockAPMServer(t testing.TB) (*http.Server, *apmServerInternals) {
...
}