Skip to content

Commit

Permalink
Fix derivation path and tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrei Bancioiu committed Apr 28, 2020
1 parent a76ecaa commit ae0a056
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,6 @@ class CoinAddressDerivationTests {
CARDANO -> assertEquals("addr1snpa4z7ntyfszv7ckquprdw75w4qjqh0qmya9jtkpxxlzxghlqyvv7l0yjamh8fxraw06p3ua8sj2g2gv98v4849s43t9g2999kquuu5egnprk", address)
NEO -> assertEquals("AT6w7PJvwPcSqHvtbNBY2aHPDv12eW5Uuf", address)
FILECOIN -> assertEquals("f1zzykebxldfcakj5wdb5n3n7priul522fnmjzori", address)
ELROND -> assertEquals("erd1k3hzqq8yffrsr86238r3avwq6w0kfgtwrjwhf72n07kxyk4nzwxqvm47d2", address)
ELROND -> assertEquals("erd1jfcy8aeru6vlx4fe6h3pc3vlpe2cnnur5zetxdhp879yagq7vqvs8na4f8", address)
}
}
2 changes: 1 addition & 1 deletion coins.json
Original file line number Diff line number Diff line change
Expand Up @@ -1337,7 +1337,7 @@
"symbol": "ERD",
"decimals": 18,
"blockchain": "ElrondNetwork",
"derivationPath": "m/44'/508'/0'",
"derivationPath": "m/44'/508'/0'/0'/0'",
"curve": "ed25519",
"publicKeyType": "ed25519",
"hrp": "erd",
Expand Down
2 changes: 1 addition & 1 deletion swift/Tests/CoinAddressDerivationTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ class CoinAddressDerivationTests: XCTestCase {
let expectedResult = "f1zzykebxldfcakj5wdb5n3n7priul522fnmjzori"
AssetCoinDerivation(coin, expectedResult, derivedAddress, address)
case .elrond:
let expectedResult = "erd1k3hzqq8yffrsr86238r3avwq6w0kfgtwrjwhf72n07kxyk4nzwxqvm47d2"
let expectedResult = "erd1jfcy8aeru6vlx4fe6h3pc3vlpe2cnnur5zetxdhp879yagq7vqvs8na4f8"
AssetCoinDerivation(coin, expectedResult, derivedAddress, address)
@unknown default:
fatalError()
Expand Down
4 changes: 2 additions & 2 deletions tests/interface/TWHDWalletTests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,8 @@ TEST(HDWallet, DeriveElrond) {
auto privateKeyData = WRAPD(TWPrivateKeyData(privateKey.get()));
auto address = WRAPS(TWCoinTypeDeriveAddress(TWCoinTypeElrond, privateKey.get()));

assertHexEqual(privateKeyData, "1e6a08a0dc7cfcafdeea72949c3f6c1f8828536727e4b3d64232609c41cb8b3e");
assertStringsEqual(address, "erd17vh5dwqrvnlxpmgwujewkuqk0rs9wkl2sgmnxgcp8ahjap5suwusqkuc5r");
assertHexEqual(privateKeyData, "0eb593141de897d60a0883320793eb49e63d556ccdf783a87ec014f150d50453");
assertStringsEqual(address, "erd1a6l7q9cfvrgr80xuzm37tapdr4zm3mwrtl6vt8f45df45x7eadfs8ds5vv");
}

TEST(HDWallet, ExtendedKeys) {
Expand Down

0 comments on commit ae0a056

Please sign in to comment.