Skip to content

Commit 547f50f

Browse files
committed
fix: broken tests after merging from develop branch
remove unexpected indentation fix indetation fix indentation fix indentation fix: missing input parameter in CreateDiggerBatch
1 parent d0c771c commit 547f50f

File tree

3 files changed

+22
-23
lines changed

3 files changed

+22
-23
lines changed

backend/controllers/github.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ import (
1717
"slices"
1818
"strconv"
1919
"strings"
20+
2021
"github.com/diggerhq/digger/backend/ci_backends"
2122
config2 "github.com/diggerhq/digger/backend/config"
2223
"github.com/diggerhq/digger/backend/locking"
@@ -726,10 +727,9 @@ func handlePullRequestEvent(gh utils.GithubClientProvider, payload *github.PullR
726727
0,
727728
aiSummaryCommentId,
728729
config.ReportTerraformOutputs,
729-
coverAllImpactedProjects,
730+
coverAllImpactedProjects,
730731
nil,
731732
)
732-
733733
if err != nil {
734734
slog.Error("Error converting jobs to Digger jobs",
735735
"prNumber", prNumber,
@@ -1533,10 +1533,9 @@ func handleIssueCommentEvent(gh utils.GithubClientProvider, payload *github.Issu
15331533
0,
15341534
aiSummaryCommentId,
15351535
config.ReportTerraformOutputs,
1536-
coverAllImpactedProjects,
1536+
coverAllImpactedProjects,
15371537
nil,
15381538
)
1539-
15401539
if err != nil {
15411540
slog.Error("Error converting jobs to Digger jobs",
15421541
"issueNumber", issueNumber,

backend/controllers/projects.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1385,7 +1385,7 @@ func AutomergePRforBatchIfEnabled(gh utils.GithubClientProvider, batch *models.D
13851385

13861386
if batch.Status == orchestrator_scheduler.BatchJobSucceeded &&
13871387
batch.BatchType == orchestrator_scheduler.DiggerCommandApply &&
1388-
batch.CoverAllImpactedProjects == true &&
1388+
batch.CoverAllImpactedProjects == true &&
13891389
automerge == true {
13901390

13911391
slog.Info("Conditions met for auto-merge, proceeding",

backend/models/storage.go

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -727,26 +727,26 @@ func (db *Database) GetDiggerBatch(batchId *uuid.UUID) (*DiggerBatch, error) {
727727
return batch, nil
728728
}
729729

730-
func (db *Database) CreateDiggerBatch(vcsType DiggerVCSType, githubInstallationId int64, repoOwner string, repoName string, repoFullname string, PRNumber int, diggerConfig string, branchName string, batchType scheduler.DiggerCommand, commentId *int64, gitlabProjectId int, aiSummaryCommentId string, reportTerraformOutputs bool, VCSConnectionId *uint) (*DiggerBatch, error) {
730+
func (db *Database) CreateDiggerBatch(vcsType DiggerVCSType, githubInstallationId int64, repoOwner string, repoName string, repoFullname string, PRNumber int, diggerConfig string, branchName string, batchType scheduler.DiggerCommand, commentId *int64, gitlabProjectId int, aiSummaryCommentId string, reportTerraformOutputs bool, coverAllImpactedProjects bool, VCSConnectionId *uint) (*DiggerBatch, error) {
731731
uid := uuid.New()
732732
batch := &DiggerBatch{
733-
ID: uid,
734-
VCS: vcsType,
735-
VCSConnectionId: VCSConnectionId,
736-
GithubInstallationId: githubInstallationId,
737-
RepoOwner: repoOwner,
738-
RepoName: repoName,
739-
RepoFullName: repoFullname,
740-
PrNumber: PRNumber,
741-
CommentId: commentId,
742-
Status: scheduler.BatchJobCreated,
743-
BranchName: branchName,
744-
DiggerConfig: diggerConfig,
745-
BatchType: batchType,
746-
GitlabProjectId: gitlabProjectId,
747-
AiSummaryCommentId: aiSummaryCommentId,
748-
ReportTerraformOutputs: reportTerraformOutputs,
749-
CoverAllImpactedProjects: coverAllImpactedProjects,
733+
ID: uid,
734+
VCS: vcsType,
735+
VCSConnectionId: VCSConnectionId,
736+
GithubInstallationId: githubInstallationId,
737+
RepoOwner: repoOwner,
738+
RepoName: repoName,
739+
RepoFullName: repoFullname,
740+
PrNumber: PRNumber,
741+
CommentId: commentId,
742+
Status: scheduler.BatchJobCreated,
743+
BranchName: branchName,
744+
DiggerConfig: diggerConfig,
745+
BatchType: batchType,
746+
GitlabProjectId: gitlabProjectId,
747+
AiSummaryCommentId: aiSummaryCommentId,
748+
ReportTerraformOutputs: reportTerraformOutputs,
749+
CoverAllImpactedProjects: coverAllImpactedProjects,
750750
}
751751
result := db.GormDB.Save(batch)
752752
if result.Error != nil {

0 commit comments

Comments
 (0)