Add test for max lenght varint
This commit is contained in:
@@ -119,6 +119,15 @@ func TestPrefixRoundtrip(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func Test16BytesVarint(t *testing.T) {
|
||||
data := []byte("this is some test content")
|
||||
hash, _ := mh.Sum(data, mh.SHA2_256, -1)
|
||||
c := NewCidV1(CBOR, hash)
|
||||
|
||||
c.codec = 1 << 54
|
||||
_ = c.Bytes()
|
||||
}
|
||||
|
||||
func TestFuzzCid(t *testing.T) {
|
||||
buf := make([]byte, 128)
|
||||
for i := 0; i < 200; i++ {
|
||||
|
||||
Reference in New Issue
Block a user