Skip to content

Commit

Permalink
address: add fuzz test
Browse files Browse the repository at this point in the history
  • Loading branch information
guggero committed Oct 5, 2023
1 parent 05f52a1 commit 3779439
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions address/address_test.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package address

import (
"bytes"
"encoding/hex"
"testing"

Expand Down Expand Up @@ -485,3 +486,10 @@ func runBIPTestVector(t *testing.T, testVectors *TestVectors) {
})
}
}

func FuzzAddressDecode(f *testing.F) {
f.Fuzz(func(t *testing.T, data []byte) {
a := &Tap{}
_ = a.Decode(bytes.NewReader(data))
})
}

0 comments on commit 3779439

Please sign in to comment.