Skip to content

Commit 72fa973

Browse files
Merge pull request #28306 from wking/return-to-structured-ClusterOperator-condition-type
pkg/monitortests/clusterversionoperator/legacycvomonitortests: Structured condition types
2 parents 025fd23 + 04401ce commit 72fa973

File tree

1 file changed

+7
-1
lines changed
  • pkg/monitortests/clusterversionoperator/legacycvomonitortests

1 file changed

+7
-1
lines changed

pkg/monitortests/clusterversionoperator/legacycvomonitortests/operators.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,13 @@ func testOperatorState(interestingCondition configv1.ClusterStatusConditionType,
276276
if eventInterval.From == eventInterval.To {
277277
continue
278278
}
279-
if !strings.Contains(eventInterval.Message, fmt.Sprintf("%v", interestingCondition)) {
279+
280+
condition := monitorapi.GetOperatorConditionStatus(eventInterval)
281+
if condition == nil {
282+
continue
283+
}
284+
285+
if condition.Type != interestingCondition {
280286
continue
281287
}
282288

0 commit comments

Comments
 (0)