MCPcopy Create free account
hub / github.com/gogs/gogs / SetMockAuth

Function SetMockAuth

internal/conf/mocks.go:16–22  ·  view source on GitHub ↗
(t *testing.T, otps AuthOpts)

Source from the content-addressed store, hash-verified

14}
15
16func SetMockAuth(t *testing.T, otps AuthOpts) {
17 before := Auth
18 Auth = otps
19 t.Cleanup(func() {
20 Auth = before
21 })
22}
23
24var mockServer sync.Mutex
25

Callers 1

TestGenerateActivateCodeFunction · 0.92

Calls

no outgoing calls

Tested by 1

TestGenerateActivateCodeFunction · 0.74