diff --git a/bitcoind-tests/Cargo.toml b/bitcoind-tests/Cargo.toml index 449114f9..8c79c914 100644 --- a/bitcoind-tests/Cargo.toml +++ b/bitcoind-tests/Cargo.toml @@ -10,4 +10,4 @@ edition = "2018" elements-miniscript = {path = "../"} elementsd = {version = "0.6.0"} actual-rand = { package = "rand", version = "0.8.4"} -secp256k1 = {version = "0.24.0", features = ["rand-std"]} +secp256k1 = {version = "0.27.0", features = ["rand-std"]} diff --git a/bitcoind-tests/tests/setup/test_util.rs b/bitcoind-tests/tests/setup/test_util.rs index fc2fafe4..848e8f18 100644 --- a/bitcoind-tests/tests/setup/test_util.rs +++ b/bitcoind-tests/tests/setup/test_util.rs @@ -59,7 +59,7 @@ pub struct PubData { #[derive(Debug, Clone)] pub struct SecretData { pub sks: Vec, - pub x_only_keypairs: Vec, + pub x_only_keypairs: Vec, pub sha256_pre: [u8; 32], pub hash256_pre: [u8; 32], pub ripemd160_pre: [u8; 32], @@ -77,7 +77,7 @@ fn setup_keys( ) -> ( Vec, Vec, - Vec, + Vec, Vec, ) { let secp_sign = secp256k1::Secp256k1::signing_only(); @@ -102,7 +102,7 @@ fn setup_keys( let mut x_only_pks = vec![]; for i in 0..n { - let keypair = bitcoin::KeyPair::from_secret_key(&secp_sign, &sks[i]); + let keypair = bitcoin::key::KeyPair::from_secret_key(&secp_sign, &sks[i]); let (xpk, _parity) = bitcoin::key::XOnlyPublicKey::from_keypair(&keypair); x_only_keypairs.push(keypair); x_only_pks.push(xpk); @@ -359,7 +359,7 @@ fn subs_hash_frag(ms: &str, pubdata: &PubData) -> String { ); let ms = ms.replace( "hash256(H)", - &format!("hash256({})", &pubdata.hash256.into_inner().to_hex()), + &format!("hash256({})", &pubdata.hash256.to_hex()), ); let ms = ms.replace( "ripemd160(H)", diff --git a/bitcoind-tests/tests/test_cpp.rs b/bitcoind-tests/tests/test_cpp.rs index ec9cc800..20e79ac9 100644 --- a/bitcoind-tests/tests/test_cpp.rs +++ b/bitcoind-tests/tests/test_cpp.rs @@ -167,7 +167,7 @@ pub fn test_from_cpp_ms(cl: &ElementsD, testdata: &TestData) { testdata.secretdata.sha256_pre.to_vec(), ); psbts[i].inputs_mut()[0].hash256_preimages.insert( - sha256d::Hash::from_inner(testdata.pubdata.hash256.into_inner()), + sha256d::Hash::from_byte_array(testdata.pubdata.hash256.to_byte_array()), testdata.secretdata.hash256_pre.to_vec(), ); println!("{}", ms); diff --git a/bitcoind-tests/tests/test_desc.rs b/bitcoind-tests/tests/test_desc.rs index 0f2a22f9..5b222819 100644 --- a/bitcoind-tests/tests/test_desc.rs +++ b/bitcoind-tests/tests/test_desc.rs @@ -150,7 +150,7 @@ pub fn test_desc_satisfy( let internal_keypair = internal_keypair .add_xonly_tweak( &secp, - &Scalar::from_be_bytes(tr.spend_info().tap_tweak().into_inner()) + &Scalar::from_be_bytes(tr.spend_info().tap_tweak().to_byte_array()) .expect("valid scalar"), ) .expect("Tweaking failed"); @@ -272,7 +272,7 @@ pub fn test_desc_satisfy( testdata.secretdata.sha256_pre.to_vec(), ); psbt.inputs_mut()[0].hash256_preimages.insert( - sha256d::Hash::from_inner(testdata.pubdata.hash256.into_inner()), + sha256d::Hash::from_byte_array(testdata.pubdata.hash256.to_byte_array()), testdata.secretdata.hash256_pre.to_vec(), ); psbt.inputs_mut()[0].hash160_preimages.insert(