Skip to content

Commit

Permalink
chore: use bytes.Equal instead
Browse files Browse the repository at this point in the history
  • Loading branch information
testwill committed Oct 19, 2023
1 parent 79ed636 commit fe94a65
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions session_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ func TestWriteTo(t *testing.T) {
t.Fatal("WriteTo nw mismatch", nw)
}

if bytes.Compare(sndbuf, rcvbuf.Bytes()) != 0 {
if !bytes.Equal(sndbuf, rcvbuf.Bytes()) {
t.Fatal("mismatched echo bytes")
}
}
Expand Down Expand Up @@ -282,7 +282,7 @@ func TestWriteToV2(t *testing.T) {
t.Fatal("WriteTo nw mismatch", nw)
}

if bytes.Compare(sndbuf, rcvbuf.Bytes()) != 0 {
if !bytes.Equal(sndbuf, rcvbuf.Bytes()) {
t.Fatal("mismatched echo bytes")
}
}
Expand Down

0 comments on commit fe94a65

Please sign in to comment.