passing middleware tests

This commit is contained in:
Marcus Efraimsson
2019-01-22 13:51:55 +01:00
parent 4096449aec
commit 59d0c19ba8
5 changed files with 92 additions and 58 deletions

View File

@ -64,7 +64,8 @@ func recoveryScenario(desc string, url string, fn scenarioFunc) {
Delims: macaron.Delims{Left: "[[", Right: "]]"},
}))
sc.m.Use(GetContextHandler(nil))
sc.userAuthTokenService = newFakeUserAuthTokenService()
sc.m.Use(GetContextHandler(sc.userAuthTokenService))
// mock out gc goroutine
session.StartSessionGC = func() {}
sc.m.Use(Sessioner(&ms.Options{}, 0))