Skip to content

Commit

Permalink
test: delete useless test case
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoguang1010 committed Oct 23, 2024
1 parent 4ea9750 commit b12c0b3
Showing 1 changed file with 0 additions and 114 deletions.
114 changes: 0 additions & 114 deletions token-core/tcx-btc-kin/src/address.rs
Original file line number Diff line number Diff line change
Expand Up @@ -514,120 +514,6 @@ mod tests {
.unwrap();
assert_eq!(account.address, "DQ4tVEqdPWHc1aVBm4Sfwft8XyNRPMEchR");
assert_eq!(account.ext_pub_key, "xpub6CDSaXHQokkKmHHG2kNCFZeirJkcZgRZE97ZZUtViif3SFHSNVAvRpWC3CxeRt2VZetEGCcPTmWEFpKF4NDeeZrMNPQgfUaX5Hkw89kW8qE");
let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/3'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "TESTNET".to_string(),
seg_wit: "NONE".to_string(),
})
.unwrap();
assert_eq!(account.address, "no7xDFaYKUkKtZ4Nnt68C5URmqkiMUTRTE");

let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "MAINNET".to_string(),
seg_wit: "P2WPKH".to_string(),
})
.unwrap();
assert_eq!(account.address, "A6tT5rU6MZBzArAVVei5PqqocfxBqJhSqg");
let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "TESTNET".to_string(),
seg_wit: "P2WPKH".to_string(),
})
.unwrap();
assert_eq!(account.address, "2N7hQQkLDtwpSUGRZkefXmfCh8SnKabUcC5");

let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "MAINNET".to_string(),
seg_wit: "VERSION_0".to_string(),
})
.unwrap();
assert_eq!(account.address, "1q8qlms89s5078yj67pr8ch02qgvmdwy0k24vwhn");
let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "TESTNET".to_string(),
seg_wit: "VERSION_0".to_string(),
})
.unwrap();
assert_eq!(account.address, "1q8qlms89s5078yj67pr8ch02qgvmdwy0k24vwhn");

let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "MAINNET".to_string(),
seg_wit: "VERSION_1".to_string(),
})
.unwrap();
assert_eq!(
account.address,
"1pd2gajgcpr7c5ajgl377sgmqexw5jxqvl305zw2a7aeujf8pun7ksh45tuj"
);
let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "TESTNET".to_string(),
seg_wit: "VERSION_1".to_string(),
})
.unwrap();
assert_eq!(
account.address,
"1pd2gajgcpr7c5ajgl377sgmqexw5jxqvl305zw2a7aeujf8pun7ksh45tuj"
);
}

#[test]
fn test_dogecoin_address2() {
let mut hd = sample_hd_keystore();
let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/0".to_string(),
curve: CurveType::SECP256k1,
network: "MAINNET".to_string(),
seg_wit: "NONE".to_string(),
})
.unwrap();
assert_eq!(account.address, "DAGWiHeAHCTLUTsBEFMWviSkdGeZGveASM");
// assert_eq!(account.ext_pub_key, "xpub6CDSaXHQokkKmHHG2kNCFZeirJkcZgRZE97ZZUtViif3SFHSNVAvRpWC3CxeRt2VZetEGCcPTmWEFpKF4NDeeZrMNPQgfUaX5Hkw89kW8qE");
let account = hd
.derive_coin::<BtcKinAddress>(&CoinInfo {
chain_id: "".to_string(),
coin: "DOGECOIN".to_string(),
derivation_path: "m/44'/1'/0'/0/22".to_string(),
curve: CurveType::SECP256k1,
network: "TESTNET".to_string(),
seg_wit: "NONE".to_string(),
})
.unwrap();
assert_eq!(account.address, "nZKaSJP5DAv4MSSNG4zyB833s92rHdzyqW");
}

#[test]
Expand Down

0 comments on commit b12c0b3

Please sign in to comment.