From 11a0803ea56fa57c4e9b2bb6dc9aad3c5190e202 Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Tue, 21 Mar 2023 18:50:23 -0400 Subject: [PATCH] Make the bitcoin Algorithm test a unit test --- coins/bitcoin/src/lib.rs | 3 +++ coins/bitcoin/{ => src}/tests/crypto.rs | 2 +- coins/bitcoin/src/tests/mod.rs | 1 + 3 files changed, 5 insertions(+), 1 deletion(-) rename coins/bitcoin/{ => src}/tests/crypto.rs (98%) create mode 100644 coins/bitcoin/src/tests/mod.rs diff --git a/coins/bitcoin/src/lib.rs b/coins/bitcoin/src/lib.rs index aee6d037..fbb52f60 100644 --- a/coins/bitcoin/src/lib.rs +++ b/coins/bitcoin/src/lib.rs @@ -14,3 +14,6 @@ pub(crate) mod crypto; pub mod wallet; /// A minimal asynchronous Bitcoin RPC client. pub mod rpc; + +#[cfg(test)] +mod tests; diff --git a/coins/bitcoin/tests/crypto.rs b/coins/bitcoin/src/tests/crypto.rs similarity index 98% rename from coins/bitcoin/tests/crypto.rs rename to coins/bitcoin/src/tests/crypto.rs index a757d439..b40f3677 100644 --- a/coins/bitcoin/tests/crypto.rs +++ b/coins/bitcoin/src/tests/crypto.rs @@ -12,7 +12,7 @@ use frost::{ tests::{algorithm_machines, key_gen, sign}, }; -use bitcoin_serai::{ +use crate::{ bitcoin::hashes::{Hash as HashTrait, sha256::Hash}, crypto::{x_only, make_even, Schnorr}, }; diff --git a/coins/bitcoin/src/tests/mod.rs b/coins/bitcoin/src/tests/mod.rs new file mode 100644 index 00000000..b3a33b17 --- /dev/null +++ b/coins/bitcoin/src/tests/mod.rs @@ -0,0 +1 @@ +mod crypto;