Skip to content

Commit

Permalink
Modifying return value of nullExact.String() (#266)
Browse files Browse the repository at this point in the history
  • Loading branch information
bendbennett committed Jan 22, 2024
1 parent 35ffc45 commit 31f8d5e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions knownvalue/null.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ func (v nullExact) CheckValue(other any) error {
return nil
}

// String returns the string representation of nil.
// String returns the string representation of null.
func (v nullExact) String() string {
return "nil"
return "null"
}

// NullExact returns a Check for asserting equality nil
Expand Down
2 changes: 1 addition & 1 deletion knownvalue/null_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func TestNullValue_String(t *testing.T) {

got := knownvalue.NullExact().String()

if diff := cmp.Diff(got, "nil"); diff != "" {
if diff := cmp.Diff(got, "null"); diff != "" {
t.Errorf("unexpected difference: %s", diff)
}
}

0 comments on commit 31f8d5e

Please sign in to comment.