File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -241,7 +241,7 @@ func TestNativeToBytes(t *testing.T) {
241241
242242 // case when the number of bytes is smaller than the length of the emulated field element
243243 assert .Run (func (assert * test.Assert ) {
244- bound := new (big.Int ).Lsh (big .NewInt (1 ), fr_bn254 .Bytes - 1 )
244+ bound := new (big.Int ).Lsh (big .NewInt (1 ), fr_bn254 .Bits - 1 )
245245 sint , err := rand .Int (rand .Reader , bound )
246246 assert .NoError (err , "failed to generate random int" )
247247 sbytes := make ([]byte , fr_bn254 .Bytes )
@@ -303,7 +303,7 @@ func TestEmulatedToBytes(t *testing.T) {
303303
304304 // case when the number of bytes is smaller than the length of the emulated field element
305305 assert .Run (func (assert * test.Assert ) {
306- bound := new (big.Int ).Lsh (big .NewInt (1 ), fp_bls12381 .Bytes - 1 )
306+ bound := new (big.Int ).Lsh (big .NewInt (1 ), fp_bls12381 .Bits - 1 )
307307 sint , err := rand .Int (rand .Reader , bound )
308308 assert .NoError (err , "failed to generate random int" )
309309 sbytes := make ([]byte , fp_bls12381 .Bytes )
You can’t perform that action at this time.
0 commit comments