Optimize CI test runtime
This PR makes 2 main changes to the tests: 1. User logins were a huge part of the total CPU time because of the constant hashing of the password. There were 3 logins every time for every `Setup()` call. We remove the `LoginSystemManager` from the Setup call as it wasn't used in a lot of tests, and call that as needed. 2. We add the new app migrations that got added after the last preload optimization was done. This shaves off around 3 mins from the test runtime. They are down from ~18m to ~15m. ```release-note NONE ``` Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
bd42f0cd8c
Коммит
696b9e0872
@@ -967,6 +967,7 @@ func TestPermanentDeleteTeam(t *testing.T) {
|
||||
|
||||
func TestGetAllTeams(t *testing.T) {
|
||||
th := Setup(t).InitBasic()
|
||||
th.LoginSystemManager()
|
||||
defer th.TearDown()
|
||||
client := th.Client
|
||||
|
||||
@@ -1403,6 +1404,7 @@ func TestGetTeamByNameSanitization(t *testing.T) {
|
||||
|
||||
func TestSearchAllTeams(t *testing.T) {
|
||||
th := Setup(t).InitBasic()
|
||||
th.LoginSystemManager()
|
||||
defer th.TearDown()
|
||||
|
||||
oTeam := th.BasicTeam
|
||||
|
||||
Ссылка в новой задаче
Block a user