Refactor tests (#26464)

1. Give the global variable clear names
2. Use generic parameter for `onGiteaRun`
This commit is contained in:
wxiaoguang authored and GitHub committed 2023-08-12 16:30:16 +00:00
1 parent bcccf4c0d6
commit c28e29fd94
12 files changed
+65 -127

No files matched your search

+2 -2
View File
@@ -208,8 +208,8 @@ func serveInstalled(ctx *cli.Context) error {
}
// Set up Chi routes
c := routers.NormalRoutes()
err := listen(c, true)
webRoutes := routers.NormalRoutes()
err := listen(webRoutes, true)
<-graceful.GetManager().Done()
log.Info("PID: %d Gitea Web Finished", os.Getpid())
log.GetManager().Close()