mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 15:11:03 +00:00
Crypto fixes/improvements (#2008)
* Crypto fixes: - Use schnorrkel's HDKD derive - Assume all key URIs beginning with `/` are prefixed with public root phrase. * Remove commented code. * Update README * Update core/primitives/src/ed25519.rs Co-Authored-By: gavofyork <github@gavwood.com>
This commit is contained in:
@@ -523,7 +523,15 @@ impl Pair {
|
||||
mod test {
|
||||
use super::*;
|
||||
use hex_literal::{hex, hex_impl};
|
||||
use crate::Pair as _Pair;
|
||||
use crate::{Pair as _Pair, crypto::DEV_PHRASE};
|
||||
|
||||
#[test]
|
||||
fn default_phrase_should_be_used() {
|
||||
assert_eq!(
|
||||
Pair::from_string("//Alice///password", None).unwrap().public(),
|
||||
Pair::from_string(&format!("{}//Alice", DEV_PHRASE), Some("password")).unwrap().public(),
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_vector_should_work() {
|
||||
|
||||
Reference in New Issue
Block a user