2021-06-03 23:24:15 +00:00
|
|
|
package test
|
|
|
|
|
|
|
|
import (
|
2021-06-26 04:46:51 +00:00
|
|
|
"github.com/fleetdm/fleet/v4/server/fleet"
|
|
|
|
"github.com/fleetdm/fleet/v4/server/ptr"
|
2021-06-03 23:24:15 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
var (
|
2021-06-06 22:07:29 +00:00
|
|
|
UserNoRoles = &fleet.User{
|
2021-06-24 20:42:29 +00:00
|
|
|
ID: 1,
|
2021-06-03 23:24:15 +00:00
|
|
|
}
|
2021-06-06 22:07:29 +00:00
|
|
|
UserAdmin = &fleet.User{
|
2021-06-03 23:24:15 +00:00
|
|
|
ID: 2,
|
2021-06-06 22:07:29 +00:00
|
|
|
GlobalRole: ptr.String(fleet.RoleAdmin),
|
2021-06-03 23:24:15 +00:00
|
|
|
}
|
2021-06-06 22:07:29 +00:00
|
|
|
UserMaintainer = &fleet.User{
|
2021-06-03 23:24:15 +00:00
|
|
|
ID: 3,
|
2021-06-06 22:07:29 +00:00
|
|
|
GlobalRole: ptr.String(fleet.RoleMaintainer),
|
2021-06-03 23:24:15 +00:00
|
|
|
}
|
2021-06-06 22:07:29 +00:00
|
|
|
UserObserver = &fleet.User{
|
2021-06-03 23:24:15 +00:00
|
|
|
ID: 4,
|
2021-06-06 22:07:29 +00:00
|
|
|
GlobalRole: ptr.String(fleet.RoleObserver),
|
2021-06-03 23:24:15 +00:00
|
|
|
}
|
2021-10-15 10:34:11 +00:00
|
|
|
UserTeamAdminTeam1 = &fleet.User{
|
|
|
|
ID: 5,
|
|
|
|
Teams: []fleet.UserTeam{
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 1},
|
|
|
|
Role: fleet.RoleAdmin,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
UserTeamAdminTeam2 = &fleet.User{
|
|
|
|
ID: 6,
|
|
|
|
Teams: []fleet.UserTeam{
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 2},
|
|
|
|
Role: fleet.RoleAdmin,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
UserTeamMaintainerTeam1 = &fleet.User{
|
|
|
|
ID: 7,
|
|
|
|
Teams: []fleet.UserTeam{
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 1},
|
|
|
|
Role: fleet.RoleMaintainer,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
UserTeamMaintainerTeam2 = &fleet.User{
|
|
|
|
ID: 8,
|
|
|
|
Teams: []fleet.UserTeam{
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 2},
|
|
|
|
Role: fleet.RoleMaintainer,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
UserTeamObserverTeam1 = &fleet.User{
|
|
|
|
ID: 9,
|
|
|
|
Teams: []fleet.UserTeam{
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 1},
|
|
|
|
Role: fleet.RoleObserver,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
UserTeamObserverTeam2 = &fleet.User{
|
|
|
|
ID: 10,
|
|
|
|
Teams: []fleet.UserTeam{
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 2},
|
|
|
|
Role: fleet.RoleObserver,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
2021-12-14 04:53:29 +00:00
|
|
|
UserTeamObserverTeam1TeamAdminTeam2 = &fleet.User{
|
|
|
|
ID: 11,
|
|
|
|
Teams: []fleet.UserTeam{
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 1},
|
|
|
|
Role: fleet.RoleObserver,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
Team: fleet.Team{ID: 2},
|
|
|
|
Role: fleet.RoleAdmin,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
2021-06-03 23:24:15 +00:00
|
|
|
)
|