Passing t to all tests setup functions (#13841)
* Passing t to all tests setup functions * Fixing build
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
3b732fe257
Коммит
1d1ab03c38
@@ -14,7 +14,7 @@ import (
|
||||
)
|
||||
|
||||
func TestGetRole(t *testing.T) {
|
||||
th := Setup().InitBasic()
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
|
||||
role := &model.Role{
|
||||
@@ -47,7 +47,7 @@ func TestGetRole(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGetRoleByName(t *testing.T) {
|
||||
th := Setup().InitBasic()
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
|
||||
role := &model.Role{
|
||||
@@ -80,7 +80,7 @@ func TestGetRoleByName(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGetRolesByNames(t *testing.T) {
|
||||
th := Setup().InitBasic()
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
|
||||
role1 := &model.Role{
|
||||
@@ -143,7 +143,7 @@ func TestGetRolesByNames(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestPatchRole(t *testing.T) {
|
||||
th := Setup().InitBasic()
|
||||
th := Setup(t).InitBasic()
|
||||
defer th.TearDown()
|
||||
|
||||
role := &model.Role{
|
||||
|
||||
Ссылка в новой задаче
Block a user