[MM-61074] Fix errcheck issues in oauth_test.go and web_test.go (#30707)
Co-authored-by: Claude <noreply@anthropic.com>
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
b8b3efda48
Коммит
bfb15ab179
@@ -18,7 +18,6 @@ import (
|
||||
// cases of the batch worker. Use the -race flag while testing this.
|
||||
func TestBatchWorkerRace(t *testing.T) {
|
||||
th := Setup(t)
|
||||
defer th.TearDown()
|
||||
|
||||
worker := jobs.MakeBatchWorker(th.Server.Jobs, th.Server.Store(), 1*time.Second, func(rctx *request.Context, job *model.Job) bool {
|
||||
return false
|
||||
@@ -59,8 +58,7 @@ func TestBatchWorker(t *testing.T) {
|
||||
}
|
||||
|
||||
t.Run("stop after first batch", func(t *testing.T) {
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
th := Setup(t).InitBasic(t)
|
||||
|
||||
var worker *jobs.BatchWorker
|
||||
worker, job := createBatchWorker(t, th, func(rctx *request.Context, job *model.Job) bool {
|
||||
@@ -86,8 +84,7 @@ func TestBatchWorker(t *testing.T) {
|
||||
})
|
||||
|
||||
t.Run("stop after second batch", func(t *testing.T) {
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
th := Setup(t).InitBasic(t)
|
||||
|
||||
var worker *jobs.BatchWorker
|
||||
worker, job := createBatchWorker(t, th, func(rctx *request.Context, job *model.Job) bool {
|
||||
@@ -113,8 +110,7 @@ func TestBatchWorker(t *testing.T) {
|
||||
})
|
||||
|
||||
t.Run("done after first batch", func(t *testing.T) {
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
th := Setup(t).InitBasic(t)
|
||||
|
||||
var worker *jobs.BatchWorker
|
||||
worker, job := createBatchWorker(t, th, func(rctx *request.Context, job *model.Job) bool {
|
||||
@@ -137,8 +133,7 @@ func TestBatchWorker(t *testing.T) {
|
||||
})
|
||||
|
||||
t.Run("done after three batches", func(t *testing.T) {
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
th := Setup(t).InitBasic(t)
|
||||
|
||||
var worker *jobs.BatchWorker
|
||||
worker, job := createBatchWorker(t, th, func(rctx *request.Context, job *model.Job) bool {
|
||||
|
||||
Ссылка в новой задаче
Block a user