Skip to content

Commit aa1886d

Browse files
committed
Micro Fixes For Source Rule Evaluation
- incidents_test.go: Remove unnecessary listener_password_hash due to updated constraint. - rule.go: Update now outdated comment.
1 parent 30d1d0a commit aa1886d

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

internal/config/rule.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ func (r *RuntimeConfig) applyPendingRules() {
115115
addToRulesBySource(curElement)
116116
}
117117

118-
// ObjectFilter{,Expr} are being initialized by config.IncrementalConfigurableInitAndValidatable.
118+
// ObjectFilterExpr is being initialized by config.IncrementalConfigurableInitAndValidatable.
119119
curElement.ObjectFilterExpr = update.ObjectFilterExpr
120120

121121
updatedSources[curElement.SourceID] = struct{}{}

internal/incident/incidents_test.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,8 @@ func TestLoadOpenIncidents(t *testing.T) {
2424

2525
// Insert a dummy source for our test cases!
2626
source := &config.Source{
27-
Type: "notifications",
28-
Name: "Icinga Notifications",
29-
ListenerPasswordHash: types.MakeString("$2y$"), // Needed to pass the database constraint.
27+
Type: "notifications",
28+
Name: "Icinga Notifications",
3029
}
3130
source.ChangedAt = types.UnixMilli(time.Date(2009, time.November, 10, 23, 0, 0, 0, time.UTC))
3231
source.Deleted = types.Bool{Bool: false, Valid: true}

0 commit comments

Comments
 (0)