mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-21 17:24:10 +00:00
Decouple unit test, remove intermediate unittestbridge
package (#17662)
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
This commit is contained in:
parent
23bd7b1211
commit
81926d61db
151 changed files with 1719 additions and 1781 deletions
|
@ -8,7 +8,6 @@ import (
|
|||
"net/http"
|
||||
"testing"
|
||||
|
||||
"code.gitea.io/gitea/models/db"
|
||||
"code.gitea.io/gitea/models/unittest"
|
||||
"code.gitea.io/gitea/models/webhook"
|
||||
"code.gitea.io/gitea/modules/context"
|
||||
|
@ -28,8 +27,8 @@ func TestTestHook(t *testing.T) {
|
|||
TestHook(&context.APIContext{Context: ctx, Org: nil})
|
||||
assert.EqualValues(t, http.StatusNoContent, ctx.Resp.Status())
|
||||
|
||||
db.AssertExistsAndLoadBean(t, &webhook.HookTask{
|
||||
unittest.AssertExistsAndLoadBean(t, &webhook.HookTask{
|
||||
RepoID: 1,
|
||||
HookID: 1,
|
||||
}, db.Cond("is_delivered=?", false))
|
||||
}, unittest.Cond("is_delivered=?", false))
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue