Move almost all functions' parameter db.Engine to context.Context (#19748)
* Move almost all functions' parameter db.Engine to context.Context * remove some unnecessary wrap functions
This commit is contained in:
parent
d81e31ad78
commit
fd7d83ace6
232 changed files with 1463 additions and 2108 deletions
|
@ -91,7 +91,7 @@ func TestUserListIsPublicMember(t *testing.T) {
|
|||
}
|
||||
|
||||
func testUserListIsPublicMember(t *testing.T, orgID int64, expected map[int64]bool) {
|
||||
org, err := GetOrgByID(orgID)
|
||||
org, err := GetOrgByID(db.DefaultContext, orgID)
|
||||
assert.NoError(t, err)
|
||||
_, membersIsPublic, err := org.GetMembers()
|
||||
assert.NoError(t, err)
|
||||
|
@ -118,7 +118,7 @@ func TestUserListIsUserOrgOwner(t *testing.T) {
|
|||
}
|
||||
|
||||
func testUserListIsUserOrgOwner(t *testing.T, orgID int64, expected map[int64]bool) {
|
||||
org, err := GetOrgByID(orgID)
|
||||
org, err := GetOrgByID(db.DefaultContext, orgID)
|
||||
assert.NoError(t, err)
|
||||
members, _, err := org.GetMembers()
|
||||
assert.NoError(t, err)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue