summaryrefslogtreecommitdiffstats
path: root/routers/api/v1
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2022-04-26 02:03:01 +0800
committerGitHub <noreply@github.com>2022-04-25 20:03:01 +0200
commit7c164d5a918c2461bbdf2a1ef79a20908c3259be (patch)
treeca46ea235e10fc43d081cd375df953e021390f0f /routers/api/v1
parent257cea654cf1fb592fdb5eacc9c1d5a97611a3f1 (diff)
downloadgitea-7c164d5a918c2461bbdf2a1ef79a20908c3259be.tar.gz
gitea-7c164d5a918c2461bbdf2a1ef79a20908c3259be.zip
Use queue instead of memory queue in webhook send service (#19390)
Diffstat (limited to 'routers/api/v1')
-rw-r--r--routers/api/v1/repo/main_test.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/routers/api/v1/repo/main_test.go b/routers/api/v1/repo/main_test.go
index 19e524d014..1f91a24937 100644
--- a/routers/api/v1/repo/main_test.go
+++ b/routers/api/v1/repo/main_test.go
@@ -9,10 +9,15 @@ import (
"testing"
"code.gitea.io/gitea/models/unittest"
+ "code.gitea.io/gitea/modules/setting"
+ webhook_service "code.gitea.io/gitea/services/webhook"
)
func TestMain(m *testing.M) {
+ setting.LoadForTest()
+ setting.NewQueueService()
unittest.MainTest(m, &unittest.TestOptions{
GiteaRootPath: filepath.Join("..", "..", "..", ".."),
+ SetUp: webhook_service.Init,
})
}