Use a context prefix for SS58 hash (#2141)

* Update to final ss58 spec

* Fix tests

* Rebuild
This commit is contained in:
Gav Wood
2019-03-29 15:44:57 +01:00
committed by GitHub
parent 0ddcbf747f
commit 5c9f306eb3
6 changed files with 17 additions and 20 deletions
-7
View File
@@ -632,13 +632,6 @@ mod test {
assert_eq!(cmp, public);
}
#[test]
fn ss58check_known_works() {
let k = "5CGavy93sZgPPjHyziRohwVumxiHXMGmQLyuqQP4ZFx5vRU9";
let enc = hex!["090fa15cb5b1666222fff584b4cc2b1761fe1e238346b340491b37e25ea183ff"];
assert_eq!(Public::from_ss58check(k).unwrap(), Public::from_raw(enc));
}
#[test]
fn verify_from_wasm_works() {
// The values in this test case are compared to the output of `node-test.js` in schnorrkel-js.