Skip to content

Commit

Permalink
feat(tomochain): rebrand to viction (#3578)
Browse files Browse the repository at this point in the history
  • Loading branch information
Milerius authored Nov 29, 2023
1 parent c94d860 commit 296f9f3
Show file tree
Hide file tree
Showing 13 changed files with 33 additions and 33 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class CoinAddressDerivationTests {
XRP -> assertEquals("rPwE3gChNKtZ1mhH3Ko8YFGqKmGRWLWXV3", address)
TEZOS -> assertEquals("tz1acnY9VbMagps26Kj3RfoGRWD9nYG5qaRX", address)
THUNDERCORE -> assertEquals("0x4b92b3ED6d8b24575Bf5ce4C6a86ED261DA0C8d7", address)
TOMOCHAIN -> assertEquals("0xC74b6D8897cBa9A4b659d43fEF73C9cA852cE424", address)
VICTION -> assertEquals("0xC74b6D8897cBa9A4b659d43fEF73C9cA852cE424", address)
TRON -> assertEquals("TQ5NMqJjhpQGK7YJbESKtNCo86PJ89ujio", address)
VECHAIN -> assertEquals("0x1a553275dF34195eAf23942CB7328AcF9d48c160", address)
WANCHAIN -> assertEquals("0xD5ca90b928279FE5D06144136a25DeD90127aC15", address)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class TestCoinType {
assertEquals(CoinType.POANETWORK.value(), 178)
assertEquals(CoinType.VECHAIN.value(), 818)
assertEquals(CoinType.ICON.value(), 74)
assertEquals(CoinType.TOMOCHAIN.value(), 889)
assertEquals(CoinType.VICTION.value(), 889)
assertEquals(CoinType.TEZOS.value(), 1729)
assertEquals(CoinType.QTUM.value(), 2301)
assertEquals(CoinType.NEBULAS.value(), 2718)
Expand Down
2 changes: 1 addition & 1 deletion docs/registry.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ This list is generated from [./registry.json](../registry.json)
| 818 | VeChain | VET | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/vechain/info/logo.png" width="32" /> | <https://vechain.org> |
| 820 | Callisto | CLO | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/callisto/info/logo.png" width="32" /> | <https://callisto.network> |
| 888 | NEO | NEO | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/neo/info/logo.png" width="32" /> | <https://neo.org> |
| 889 | TomoChain | TOMO | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/tomochain/info/logo.png" width="32" /> | <https://tomochain.com> |
| 889 | Viction | VIC | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/viction/info/logo.png" width="32" /> | <https://www.viction.xyz/> |
| 899 | eCash | XEC | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/ecash/info/logo.png" width="32" /> | <https://e.cash> |
| 931 | THORChain | RUNE | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/thorchain/info/logo.png" width="32" /> | <https://thorchain.org> |
| 966 | Polygon | MATIC | <img src="https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/polygon/info/logo.png" width="32" /> | <https://polygon.technology> |
Expand Down
2 changes: 1 addition & 1 deletion include/TrustWalletCore/TWCoinType.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ enum TWCoinType {
TWCoinTypeTheta = 500,
TWCoinTypeThunderCore = 1001,
TWCoinTypeNEO = 888,
TWCoinTypeTomoChain = 889,
TWCoinTypeViction = 889,
TWCoinTypeTron = 195,
TWCoinTypeVeChain = 818,
TWCoinTypeViacoin = 14,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class CoinAddressDerivationTests {
XRP -> "rPwE3gChNKtZ1mhH3Ko8YFGqKmGRWLWXV3"
Tezos -> "tz1acnY9VbMagps26Kj3RfoGRWD9nYG5qaRX"
ThunderCore -> "0x4b92b3ED6d8b24575Bf5ce4C6a86ED261DA0C8d7"
TomoChain -> "0xC74b6D8897cBa9A4b659d43fEF73C9cA852cE424"
Viction -> "0xC74b6D8897cBa9A4b659d43fEF73C9cA852cE424"
Tron -> "TQ5NMqJjhpQGK7YJbESKtNCo86PJ89ujio"
VeChain -> "0x1a553275dF34195eAf23942CB7328AcF9d48c160"
Wanchain -> "0xD5ca90b928279FE5D06144136a25DeD90127aC15"
Expand Down
12 changes: 6 additions & 6 deletions registry.json
Original file line number Diff line number Diff line change
Expand Up @@ -2573,10 +2573,10 @@
}
},
{
"id": "tomochain",
"name": "TomoChain",
"id": "viction",
"name": "Viction",
"coinId": 889,
"symbol": "TOMO",
"symbol": "VIC",
"decimals": 18,
"blockchain": "Ethereum",
"derivation": [
Expand All @@ -2589,15 +2589,15 @@
"chainId": "88",
"addressHasher": "keccak256",
"explorer": {
"url": "https://tomoscan.io",
"url": "https://www.vicscan.xyz",
"txPath": "/tx/",
"accountPath": "/address/",
"sampleTx": "0x35a8d3ab06c94d5b7d27221b7c9a24ba3f1710dd0fcfd75c5d59b3a885fd709b",
"sampleAccount": "0x86cCbD9bfb371c355202086882bC644A7D0b024B"
},
"info": {
"url": "https://tomochain.com",
"source": "https://github.com/tomochain/tomochain",
"url": "https://www.viction.xyz/",
"source": "https://github.com/BuildOnViction/tomochain",
"rpc": "https://rpc.tomochain.com",
"documentation": "https://eth.wiki/json-rpc/API"
}
Expand Down
2 changes: 1 addition & 1 deletion rust/tw_any_coin/tests/coin_address_derivation_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ fn test_coin_address_derivation() {
| CoinType::Theta
| CoinType::ThetaFuel
| CoinType::ThunderCore
| CoinType::TomoChain
| CoinType::Viction
| CoinType::VeChain
| CoinType::Wanchain
| CoinType::xDai
Expand Down
2 changes: 1 addition & 1 deletion swift/Tests/CoinAddressDerivationTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ class CoinAddressDerivationTests: XCTestCase {
case .thunderCore:
let expectedResult = "0x4b92b3ED6d8b24575Bf5ce4C6a86ED261DA0C8d7"
assertCoinDerivation(coin, expectedResult, derivedAddress, address)
case .tomoChain:
case .viction:
let expectedResult = "0xC74b6D8897cBa9A4b659d43fEF73C9cA852cE424"
assertCoinDerivation(coin, expectedResult, derivedAddress, address)
case .tron:
Expand Down
2 changes: 1 addition & 1 deletion swift/Tests/CoinTypeTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class CoinTypeTests: XCTestCase {
XCTAssertEqual(CoinType.poanetwork.rawValue, 178)
XCTAssertEqual(CoinType.veChain.rawValue, 818)
XCTAssertEqual(CoinType.icon.rawValue, 74)
XCTAssertEqual(CoinType.tomoChain.rawValue, 889)
XCTAssertEqual(CoinType.viction.rawValue, 889)
XCTAssertEqual(CoinType.tezos.rawValue, 1729)
XCTAssertEqual(CoinType.qtum.rawValue, 2301)
XCTAssertEqual(CoinType.nebulas.rawValue, 2718)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,22 @@
#include <gtest/gtest.h>


TEST(TWTomoChainCoinType, TWCoinType) {
auto symbol = WRAPS(TWCoinTypeConfigurationGetSymbol(TWCoinTypeTomoChain));
TEST(TWVictionType, TWCoinType) {
auto symbol = WRAPS(TWCoinTypeConfigurationGetSymbol(TWCoinTypeViction));
auto txId = WRAPS(TWStringCreateWithUTF8Bytes("0x35a8d3ab06c94d5b7d27221b7c9a24ba3f1710dd0fcfd75c5d59b3a885fd709b"));
auto txUrl = WRAPS(TWCoinTypeConfigurationGetTransactionURL(TWCoinTypeTomoChain, txId.get()));
auto txUrl = WRAPS(TWCoinTypeConfigurationGetTransactionURL(TWCoinTypeViction, txId.get()));
auto accId = WRAPS(TWStringCreateWithUTF8Bytes("0x86cCbD9bfb371c355202086882bC644A7D0b024B"));
auto accUrl = WRAPS(TWCoinTypeConfigurationGetAccountURL(TWCoinTypeTomoChain, accId.get()));
auto id = WRAPS(TWCoinTypeConfigurationGetID(TWCoinTypeTomoChain));
auto name = WRAPS(TWCoinTypeConfigurationGetName(TWCoinTypeTomoChain));
auto accUrl = WRAPS(TWCoinTypeConfigurationGetAccountURL(TWCoinTypeViction, accId.get()));
auto id = WRAPS(TWCoinTypeConfigurationGetID(TWCoinTypeViction));
auto name = WRAPS(TWCoinTypeConfigurationGetName(TWCoinTypeViction));

ASSERT_EQ(TWCoinTypeConfigurationGetDecimals(TWCoinTypeTomoChain), 18);
ASSERT_EQ(TWBlockchainEthereum, TWCoinTypeBlockchain(TWCoinTypeTomoChain));
ASSERT_EQ(0x0, TWCoinTypeP2shPrefix(TWCoinTypeTomoChain));
ASSERT_EQ(0x0, TWCoinTypeStaticPrefix(TWCoinTypeTomoChain));
assertStringsEqual(symbol, "TOMO");
assertStringsEqual(txUrl, "https://tomoscan.io/tx/0x35a8d3ab06c94d5b7d27221b7c9a24ba3f1710dd0fcfd75c5d59b3a885fd709b");
assertStringsEqual(accUrl, "https://tomoscan.io/address/0x86cCbD9bfb371c355202086882bC644A7D0b024B");
assertStringsEqual(id, "tomochain");
assertStringsEqual(name, "TomoChain");
ASSERT_EQ(TWCoinTypeConfigurationGetDecimals(TWCoinTypeViction), 18);
ASSERT_EQ(TWBlockchainEthereum, TWCoinTypeBlockchain(TWCoinTypeViction));
ASSERT_EQ(0x0, TWCoinTypeP2shPrefix(TWCoinTypeViction));
ASSERT_EQ(0x0, TWCoinTypeStaticPrefix(TWCoinTypeViction));
assertStringsEqual(symbol, "VIC");
assertStringsEqual(txUrl, "https://www.vicscan.xyz/tx/0x35a8d3ab06c94d5b7d27221b7c9a24ba3f1710dd0fcfd75c5d59b3a885fd709b");
assertStringsEqual(accUrl, "https://www.vicscan.xyz/address/0x86cCbD9bfb371c355202086882bC644A7D0b024B");
assertStringsEqual(id, "viction");
assertStringsEqual(name, "Viction");
}
2 changes: 1 addition & 1 deletion tests/common/CoinAddressDerivationTests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ TEST(Coin, DeriveAddress) {
case TWCoinTypeTheta:
case TWCoinTypeThetaFuel:
case TWCoinTypeThunderCore:
case TWCoinTypeTomoChain:
case TWCoinTypeViction:
case TWCoinTypeVeChain:
case TWCoinTypeWanchain:
case TWCoinTypeXDai:
Expand Down
4 changes: 2 additions & 2 deletions tests/interface/TWCoinTypeTests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ TEST(TWCoinType, TWPurpose) {
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeTezos));
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeTheta));
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeThunderCore));
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeTomoChain));
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeViction));
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeTron));
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeVeChain));
ASSERT_EQ(TWPurposeBIP44, TWCoinTypePurpose(TWCoinTypeWanchain));
Expand Down Expand Up @@ -130,7 +130,7 @@ TEST(TWCoinType, TWPublicKeyType) {
ASSERT_EQ(TWPublicKeyTypeED25519, TWCoinTypePublicKeyType(TWCoinTypeTezos));
ASSERT_EQ(TWPublicKeyTypeSECP256k1Extended, TWCoinTypePublicKeyType(TWCoinTypeTheta));
ASSERT_EQ(TWPublicKeyTypeSECP256k1Extended, TWCoinTypePublicKeyType(TWCoinTypeThunderCore));
ASSERT_EQ(TWPublicKeyTypeSECP256k1Extended, TWCoinTypePublicKeyType(TWCoinTypeTomoChain));
ASSERT_EQ(TWPublicKeyTypeSECP256k1Extended, TWCoinTypePublicKeyType(TWCoinTypeViction));
ASSERT_EQ(TWPublicKeyTypeSECP256k1Extended, TWCoinTypePublicKeyType(TWCoinTypeTron));
ASSERT_EQ(TWPublicKeyTypeSECP256k1Extended, TWCoinTypePublicKeyType(TWCoinTypeVeChain));
ASSERT_EQ(TWPublicKeyTypeSECP256k1Extended, TWCoinTypePublicKeyType(TWCoinTypeWanchain));
Expand Down
2 changes: 1 addition & 1 deletion tests/interface/TWHRPTests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ TEST(TWHPR, HPRByCoinType) {
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeTezos));
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeTheta));
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeThunderCore));
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeTomoChain));
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeViction));
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeTron));
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeVeChain));
ASSERT_EQ(TWHRPUnknown, TWCoinTypeHRP(TWCoinTypeWanchain));
Expand Down

0 comments on commit 296f9f3

Please sign in to comment.