Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Commit

Permalink
Ensure we do have an error before testing it
Browse files Browse the repository at this point in the history
Signed-off-by: Sylvain Rabot <s.rabot@lectra.com>
  • Loading branch information
Sylvain Rabot committed Nov 28, 2018
1 parent 7cf913f commit bbaaf4d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/api/vlabs/validate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1943,7 +1943,9 @@ func TestProperties_ValidateZones(t *testing.T) {
ExcludeMasterFromStandardLB: helpers.PointerToBool(test.excludeMasterFromStandardLB),
}

err := p.Validate(false)
if err := p.Validate(false); err == nil {
t.Errorf("error should have occurred")
}

expectedMsg := test.expectedErr
if err.Error() != expectedMsg {
Expand Down

0 comments on commit bbaaf4d

Please sign in to comment.