[TESTS] testMiddlewareHook, dependency injection in integration tests
(cherry picked from commit6623630d10
) (cherry picked from commitd30b9dc5b4
) (cherry picked from commit8e790a65ba
) (cherry picked from commit9d98ba7e5c
)
This commit is contained in:
parent
cfaff08996
commit
07fc55a3a7
6 changed files with 28 additions and 19 deletions
|
@ -10,17 +10,16 @@ import (
|
|||
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
api "code.gitea.io/gitea/modules/structs"
|
||||
"code.gitea.io/gitea/routers"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestNodeinfo(t *testing.T) {
|
||||
setting.Federation.Enabled = true
|
||||
c = routers.NormalRoutes()
|
||||
setNormalRoutes()
|
||||
defer func() {
|
||||
setting.Federation.Enabled = false
|
||||
c = routers.NormalRoutes()
|
||||
setNormalRoutes()
|
||||
}()
|
||||
|
||||
onGiteaRun(t, func(*testing.T, *url.URL) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue