Skip to content

Commit

Permalink
updated per code review
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick Zheng <[email protected]>
  • Loading branch information
Two-Hearts committed Oct 29, 2024
1 parent 3ebd9c3 commit 640b430
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion request_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ func TestNewRequest(t *testing.T) {

defaultRandReader := rand.Reader
rand.Reader = &dummyRandReader{}
defer func() {
rand.Reader = defaultRandReader
}()
opts = RequestOptions{
Content: message,
HashAlgorithm: crypto.SHA256,
Expand All @@ -84,7 +87,6 @@ func TestNewRequest(t *testing.T) {
if err == nil || !errors.As(err, &malformedRequest) || err.Error() != expectedErrMsg {
t.Fatalf("expected error %s, but got %v", expectedErrMsg, err)
}
rand.Reader = defaultRandReader
}

func TestRequestMarshalBinary(t *testing.T) {
Expand Down

0 comments on commit 640b430

Please sign in to comment.