Skip to content

Commit

Permalink
feat(response_test.go): add test with equal prefixes (#8)
Browse files Browse the repository at this point in the history
The `example.co.` and `example.co.uk.` domains have equal prefixes but
are different. Let us make sure we return false also in such a case, for
extra robustness.
  • Loading branch information
bassosimone authored Nov 19, 2024
1 parent 698f5c3 commit 95b7df4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions response_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ func Test_equalASCIIName(t *testing.T) {
{"EqualNamesDifferentCase", "Example.COM.", "exaMple.com.", true},
{"DifferentNames", "example.com.", "example.org.", false},
{"DifferentLengths", "example.com.", "example.co.uk.", false},
{"OnlyPrefixMatch", "example.co.", "example.co.uk.", false},
{"EmptyStrings", "", "", true},
{"OneEmptyString", "example.com.", "", false},
}
Expand Down

0 comments on commit 95b7df4

Please sign in to comment.