Browse Source

tests(db): fix data race (#7444)

[skip ci]
Joe Chen 2 years ago
parent
commit
ada1083462
1 changed files with 2 additions and 0 deletions
  1. 2 0
      internal/db/actions_test.go

+ 2 - 0
internal/db/actions_test.go

@@ -148,6 +148,8 @@ func actionsCommitRepo(t *testing.T, db *actions) {
 
 	now := time.Unix(1588568886, 0).UTC()
 
+	conf.SetMockSSH(t, conf.SSHOpts{})
+
 	t.Run("new commit", func(t *testing.T) {
 		t.Cleanup(func() {
 			err := db.Session(&gorm.Session{AllowGlobalUpdate: true}).WithContext(ctx).Delete(new(Action)).Error