Changeset View
Changeset View
Standalone View
Standalone View
src/test/fuzz/key.cpp
Show First 20 Lines • Show All 79 Lines • ▼ Show 20 Lines | if (!key.IsValid()) { | ||||
negated_key.Negate(); | negated_key.Negate(); | ||||
assert(negated_key.IsValid()); | assert(negated_key.IsValid()); | ||||
assert(!(negated_key == key)); | assert(!(negated_key == key)); | ||||
negated_key.Negate(); | negated_key.Negate(); | ||||
assert(negated_key == key); | assert(negated_key == key); | ||||
} | } | ||||
const uint256 random_uint256 = Hash(buffer.begin(), buffer.end()); | const uint256 random_uint256 = Hash(buffer); | ||||
{ | { | ||||
CKey child_key; | CKey child_key; | ||||
ChainCode child_chaincode; | ChainCode child_chaincode; | ||||
const bool ok = | const bool ok = | ||||
key.Derive(child_key, child_chaincode, 0, random_uint256); | key.Derive(child_key, child_chaincode, 0, random_uint256); | ||||
assert(ok); | assert(ok); | ||||
assert(child_key.IsValid()); | assert(child_key.IsValid()); | ||||
▲ Show 20 Lines • Show All 246 Lines • Show Last 20 Lines |