Skip to content

Commit 10ed8da

Browse files
authored
Correctly check for different golang versions #1076 (#1083)
1 parent 87a2fe7 commit 10ed8da

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

errors/error_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,8 @@ func TestWrap(t *testing.T) {
240240
if err.ErrorCode != int(CertificateError)+int(VerifyFailed)+certificateInvalid+int(x509.Expired) {
241241
t.Fatal("Error code construction failed.")
242242
}
243-
if err.Message != "x509: certificate has expired or is not yet valid" {
243+
errorString := "x509: certificate has expired or is not yet valid:"
244+
if err.Message[:49] != errorString[:49] {
244245
t.Fatal("Error message construction failed.")
245246
}
246247

0 commit comments

Comments
 (0)