Skip to content
This repository has been archived by the owner on Feb 16, 2024. It is now read-only.

Commit

Permalink
fix test case
Browse files Browse the repository at this point in the history
Signed-off-by: Shubham Gupta <iamshubhamgupta2001@gmail.com>
  • Loading branch information
shubham-cmyk committed Sep 16, 2023
1 parent cb8cfe6 commit 648c292
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions pkg/apis/testharness/v1beta1/commands.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ func (e *ExpectedOutput) validateOutput(outputType string, actualValue string) e
return fmt.Errorf("%s did not match wildcard pattern: %s", outputType, expectedValue)
}

case MatchEquals:
case MatchEquals:
if actualValue != expectedValue {
return fmt.Errorf("expected exact %s: %s, got: %s", outputType, expectedValue, actualValue)
}
default: // MatchEquals
default: // Throw an error if we don't recognise the match type
return fmt.Errorf("unrecognised match type %s", matchType)
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/apis/testharness/v1beta1/commands_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ func TestValidateCommandOutput(t *testing.T) {
b.WriteString("Hello, World!")
return b
}(),
wantErr: false,
wantErr: true,
},
}

Expand Down

0 comments on commit 648c292

Please sign in to comment.