chore_: Remove Goerli code (#21508)
This commit removes the goerli-related code from the mobile repo. Signed-off-by: Mohamed Javid <19339952+smohamedjavid@users.noreply.github.com>
This commit is contained in:
parent
8e7d5233df
commit
9f1eb60e21
1
.env
1
.env
|
@ -1,6 +1,5 @@
|
|||
CACHED_WEBVIEWS_ENABLED=1
|
||||
DEBUG_WEBVIEW=1
|
||||
DEFAULT_NETWORK=mainnet_rpc
|
||||
DEV_BUILD=1
|
||||
ETHEREUM_DEV_CLUSTER=1
|
||||
EXTENSIONS=0
|
||||
|
|
5
.env.e2e
5
.env.e2e
|
@ -1,5 +1,4 @@
|
|||
DEBUG_WEBVIEW=1
|
||||
DEFAULT_NETWORK=goerli_rpc
|
||||
ETHEREUM_DEV_CLUSTER=1
|
||||
EXTENSIONS=0
|
||||
FLEET=status.staging
|
||||
|
@ -22,8 +21,8 @@ KEYCARD_TEST_MENU=1
|
|||
QR_READ_TEST_MENU=1
|
||||
ENABLE_ROOT_ALERT=0
|
||||
APN_TOPIC=im.status.ethereum.pr
|
||||
VERIFY_TRANSACTION_CHAIN_ID=5
|
||||
VERIFY_ENS_CHAIN_ID=5
|
||||
VERIFY_TRANSACTION_CHAIN_ID=11155111
|
||||
VERIFY_ENS_CHAIN_ID=11155111
|
||||
TEST_STATEOFUS=1
|
||||
DATABASE_MANAGEMENT_ENABLED=1
|
||||
COMMUNITIES_ENABLED=1
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
CACHED_WEBVIEWS_ENABLED=1
|
||||
DEBUG_WEBVIEW=1
|
||||
DEFAULT_NETWORK=goerli_rpc
|
||||
ETHEREUM_DEV_CLUSTER=1
|
||||
EXTENSIONS=0
|
||||
GROUP_CHATS_ENABLED=1
|
||||
|
@ -21,8 +20,8 @@ KEYCARD_TEST_MENU=0
|
|||
ENABLE_ROOT_ALERT=1
|
||||
DISABLE_WALLET_ON_MOBILE_NETWORK=1
|
||||
APN_TOPIC=im.status.ethereum.pr
|
||||
VERIFY_TRANSACTION_CHAIN_ID=5
|
||||
VERIFY_ENS_CHAIN_ID=5
|
||||
VERIFY_TRANSACTION_CHAIN_ID=11155111
|
||||
VERIFY_ENS_CHAIN_ID=11155111
|
||||
TEST_STATEOFUS=1
|
||||
BLANK_PREVIEW=0
|
||||
DATABASE_MANAGEMENT_ENABLED=1
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
DEBUG_WEBVIEW=1
|
||||
DEFAULT_NETWORK=mainnet_rpc
|
||||
ETHEREUM_DEV_CLUSTER=1
|
||||
EXTENSIONS=0
|
||||
GROUP_CHATS_ENABLED=1
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
DEBUG_WEBVIEW=0
|
||||
DEFAULT_NETWORK=mainnet_rpc
|
||||
ETHEREUM_DEV_CLUSTER=0
|
||||
EXTENSIONS=0
|
||||
GROUP_CHATS_ENABLED=1
|
||||
|
|
|
@ -92,7 +92,7 @@ For particular example it was failed on `Recover access(password:qwerty, keycard
|
|||
Not all features of the app could be covered by e2e at the moment:
|
||||
|
||||
- Colours or place of an element on UI.
|
||||
- Real ETH/token transactions. That’s the main reason we have separate .apk build for automation needs - it defaults to Goerli network. Also it has enabled keycard test menu, ENS names and chat commands are also on Goerli network (the same in PR builds, but not in nightlies / release)
|
||||
- Real ETH/token transactions. That’s the main reason we have separate .apk build for automation needs - it defaults to Sepolia network. Also it has enabled keycard test menu, ENS names and chat commands are also on Sepolia network (the same in PR builds, but not in nightlies / release)
|
||||
- Autologin/Biometric related actions (autologin available when device meets certain conditions like the it has set unlock password and device is not rooted: all emulators are rooted in SauceLabs)
|
||||
|
||||
## Brief flow for test to be automated
|
||||
|
|
|
@ -14,9 +14,8 @@ RCT_EXPORT_MODULE();
|
|||
RCT_EXPORT_METHOD(sendLogs:(NSString *)dbJson
|
||||
jsLogs:(NSString *)jsLogs
|
||||
callback:(RCTResponseSenderBlock)callback) {
|
||||
// TODO: Implement SendLogs for iOS
|
||||
#if DEBUG
|
||||
NSLog(@"SendLogs() method called, not implemented");
|
||||
NSLog(@"SendLogs() method called");
|
||||
#endif
|
||||
NSFileManager *fileManager = [NSFileManager defaultManager];
|
||||
NSError *error = nil;
|
||||
|
@ -34,25 +33,6 @@ RCT_EXPORT_METHOD(sendLogs:(NSString *)dbJson
|
|||
|
||||
NSURL *dbFile = [logsFolderName URLByAppendingPathComponent:@"db.json"];
|
||||
NSURL *jsLogsFile = [logsFolderName URLByAppendingPathComponent:@"Status.log"];
|
||||
#if DEBUG
|
||||
NSString *networkDirPath = @"ethereum/mainnet_rpc_dev";
|
||||
#else
|
||||
NSString *networkDirPath = @"ethereum/mainnet_rpc";
|
||||
#endif
|
||||
|
||||
#if DEBUG
|
||||
NSString *goerliNetworkDirPath = @"ethereum/goerli_rpc_dev";
|
||||
#else
|
||||
NSString *goerliNetworkDirPath = @"ethereum/goerli_rpc";
|
||||
#endif
|
||||
|
||||
NSURL *networkDir = [rootUrl URLByAppendingPathComponent:networkDirPath];
|
||||
NSURL *originalGethLogsFile = [networkDir URLByAppendingPathComponent:@"geth.log"];
|
||||
NSURL *gethLogsFile = [logsFolderName URLByAppendingPathComponent:@"mainnet_geth.log"];
|
||||
|
||||
NSURL *goerliNetworkDir = [rootUrl URLByAppendingPathComponent:goerliNetworkDirPath];
|
||||
NSURL *goerliGethLogsFile = [goerliNetworkDir URLByAppendingPathComponent:@"geth.log"];
|
||||
NSURL *goerliLogsFile = [logsFolderName URLByAppendingPathComponent:@"goerli_geth.log"];
|
||||
|
||||
NSURL *mainGethLogsFile = [rootUrl URLByAppendingPathComponent:@"geth.log"];
|
||||
NSURL *mainLogsFile = [logsFolderName URLByAppendingPathComponent:@"geth.log"];
|
||||
|
@ -62,10 +42,6 @@ RCT_EXPORT_METHOD(sendLogs:(NSString *)dbJson
|
|||
[dbJson writeToFile:dbFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
||||
[jsLogs writeToFile:jsLogsFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
||||
|
||||
//NSString* gethLogs = StatusgoExportNodeLogs();
|
||||
//[gethLogs writeToFile:gethLogsFile.path atomically:YES encoding:NSUTF8StringEncoding error:nil];
|
||||
[fileManager copyItemAtPath:originalGethLogsFile.path toPath:gethLogsFile.path error:nil];
|
||||
[fileManager copyItemAtPath:goerliGethLogsFile.path toPath:goerliLogsFile.path error:nil];
|
||||
[fileManager copyItemAtPath:mainGethLogsFile.path toPath:mainLogsFile.path error:nil];
|
||||
|
||||
if ([fileManager fileExistsAtPath:requestsLogFile.path]) {
|
||||
|
|
|
@ -32,12 +32,9 @@ trap "rm -vf ${SECRETS_FILE_PATH}" EXIT ERR INT QUIT
|
|||
# Names of variables containing secrets to save in env file.
|
||||
SECRETS_ENV_VARS=(
|
||||
'ALCHEMY_ETHEREUM_MAINNET_TOKEN'
|
||||
'ALCHEMY_ETHEREUM_GOERLI_TOKEN'
|
||||
'ALCHEMY_ETHEREUM_SEPOLIA_TOKEN'
|
||||
'ALCHEMY_ARBITRUM_GOERLI_TOKEN'
|
||||
'ALCHEMY_ARBITRUM_MAINNET_TOKEN'
|
||||
'ALCHEMY_ARBITRUM_SEPOLIA_TOKEN'
|
||||
'ALCHEMY_OPTIMISM_GOERLI_TOKEN'
|
||||
'ALCHEMY_OPTIMISM_MAINNET_TOKEN'
|
||||
'ALCHEMY_OPTIMISM_SEPOLIA_TOKEN'
|
||||
'RARIBLE_MAINNET_API_KEY'
|
||||
|
|
|
@ -75,13 +75,10 @@
|
|||
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
||||
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
||||
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
||||
:compiler-options {:output-feature-set :es5
|
||||
;; We disable `:fn-deprecated` warnings because we
|
||||
|
@ -114,13 +111,10 @@
|
|||
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
||||
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
||||
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
||||
:compiler-options {:output-feature-set :es6
|
||||
;;disable for android build as there
|
||||
|
@ -158,13 +152,10 @@
|
|||
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
||||
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
||||
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
||||
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"
|
||||
status-im.config/WALLET_CONNECT_PROJECT_ID #shadow/env "WALLET_CONNECT_PROJECT_ID"}
|
||||
:compiler-options
|
||||
|
|
|
@ -20,9 +20,9 @@
|
|||
{:mainnet {:name "Ether"
|
||||
:symbol :ETH
|
||||
:decimals 18}
|
||||
:goerli {:name "Goerli Ether"
|
||||
:sepolia {:name "Sepolia Ether"
|
||||
:symbol :ETH
|
||||
:symbol-display :ETHgo
|
||||
:symbol-display :ETH
|
||||
:decimals 18}
|
||||
:xdai {:name "xDAI"
|
||||
:symbol :ETH
|
||||
|
|
|
@ -15,12 +15,12 @@
|
|||
|
||||
(def etherscan-supported?
|
||||
#{(chain/chain-keyword->chain-id :mainnet)
|
||||
(chain/chain-keyword->chain-id :goerli)})
|
||||
(chain/chain-keyword->chain-id :sepolia)})
|
||||
|
||||
(def binance-mainnet-chain-id (chain/chain-keyword->chain-id :bsc))
|
||||
(def binance-testnet-chain-id (chain/chain-keyword->chain-id :bsc-testnet))
|
||||
|
||||
(def network->subdomain {5 "goerli"})
|
||||
(def network->subdomain {11155111 "sepolia"})
|
||||
|
||||
(defn get-transaction-details-url
|
||||
[chain-id tx-hash]
|
||||
|
|
|
@ -18,28 +18,23 @@
|
|||
(goog-define RARIBLE_MAINNET_API_KEY "")
|
||||
(goog-define RARIBLE_TESTNET_API_KEY "")
|
||||
(goog-define ALCHEMY_ETHEREUM_MAINNET_TOKEN "")
|
||||
(goog-define ALCHEMY_ETHEREUM_GOERLI_TOKEN "")
|
||||
(goog-define ALCHEMY_ETHEREUM_SEPOLIA_TOKEN "")
|
||||
(goog-define ALCHEMY_ARBITRUM_MAINNET_TOKEN "")
|
||||
(goog-define ALCHEMY_ARBITRUM_GOERLI_TOKEN "")
|
||||
(goog-define ALCHEMY_ARBITRUM_SEPOLIA_TOKEN "")
|
||||
(goog-define ALCHEMY_OPTIMISM_MAINNET_TOKEN "")
|
||||
(goog-define ALCHEMY_OPTIMISM_GOERLI_TOKEN "")
|
||||
(goog-define ALCHEMY_OPTIMISM_SEPOLIA_TOKEN "")
|
||||
(goog-define WALLET_CONNECT_PROJECT_ID "87815d72a81d739d2a7ce15c2cfdefb3")
|
||||
(goog-define MIXPANEL_APP_ID "3350627")
|
||||
(goog-define MIXPANEL_TOKEN "5c73bda2d36a9f688a5ee45641fb6775")
|
||||
|
||||
(def mainnet-rpc-url (str "https://eth-archival.rpc.grove.city/v1/" POKT_TOKEN))
|
||||
(def goerli-rpc-url (str "https://goerli-archival.gateway.pokt.network/v1/lb/" POKT_TOKEN))
|
||||
(def sepolia-rpc-url (str "https://sepolia-archival.rpc.grove.city/v1/" POKT_TOKEN))
|
||||
(def mainnet-chain-explorer-link "https://etherscan.io/address/")
|
||||
(def optimism-mainnet-chain-explorer-link "https://optimistic.etherscan.io/address/")
|
||||
(def arbitrum-mainnet-chain-explorer-link "https://arbiscan.io/address/")
|
||||
(def sepolia-chain-explorer-link "https://sepolia.etherscan.io/address/")
|
||||
(def optimism-sepolia-chain-explorer-link "https://sepolia-optimistic.etherscan.io/address/")
|
||||
(def arbitrum-sepolia-chain-explorer-link "https://sepolia.arbiscan.io/address/")
|
||||
(def goerli-chain-explorer-link "https://goerli.etherscan.io/address/")
|
||||
(def optimism-goerli-chain-explorer-link "https://goerli-optimistic.etherscan.io/address/")
|
||||
(def opensea-link "https://opensea.io")
|
||||
(def opensea-tesnet-link "https://testnets.opensea.io")
|
||||
|
||||
|
@ -79,7 +74,6 @@
|
|||
(def log-request-go (enabled? (get-config :LOG_REQUEST_GO "0")))
|
||||
(def fleet (get-config :FLEET ""))
|
||||
(def apn-topic (get-config :APN_TOPIC "im.status.ethereum"))
|
||||
(def default-network (get-config :DEFAULT_NETWORK "goerli_rpc"))
|
||||
(def max-installations 2)
|
||||
; currently not supported in status-go
|
||||
(def enable-remove-profile-picture? false)
|
||||
|
@ -100,13 +94,13 @@
|
|||
(def verify-transaction-url
|
||||
(if (= :mainnet (chain/chain-id->chain-keyword verify-transaction-chain-id))
|
||||
mainnet-rpc-url
|
||||
goerli-rpc-url))
|
||||
sepolia-rpc-url))
|
||||
|
||||
(def verify-ens-chain-id (js/parseInt (get-config :VERIFY_ENS_CHAIN_ID "1")))
|
||||
(def verify-ens-url
|
||||
(if (= :mainnet (chain/chain-id->chain-keyword verify-ens-chain-id))
|
||||
mainnet-rpc-url
|
||||
goerli-rpc-url))
|
||||
sepolia-rpc-url))
|
||||
(def verify-ens-contract-address
|
||||
(get-config :VERIFY_ENS_CONTRACT_ADDRESS
|
||||
((chain/chain-id->chain-keyword verify-ens-chain-id) utils.ens/ens-registries)))
|
||||
|
|
|
@ -473,30 +473,22 @@
|
|||
|
||||
;; wallet
|
||||
(def ^:const ethereum-mainnet-chain-id 1)
|
||||
(def ^:const ethereum-goerli-chain-id 5)
|
||||
(def ^:const ethereum-sepolia-chain-id 11155111)
|
||||
(def ^:const arbitrum-mainnet-chain-id 42161)
|
||||
(def ^:const arbitrum-goerli-chain-id 421613)
|
||||
(def ^:const arbitrum-sepolia-chain-id 421614)
|
||||
(def ^:const optimism-mainnet-chain-id 10)
|
||||
(def ^:const optimism-goerli-chain-id 420)
|
||||
(def ^:const optimism-sepolia-chain-id 11155420)
|
||||
|
||||
(def opensea-url-names
|
||||
{:ethereum "ethereum"
|
||||
:sepolia "sepolia"
|
||||
:goerli "goerli"})
|
||||
:sepolia "sepolia"})
|
||||
|
||||
(def ^:const ethereum "ethereum")
|
||||
(def ^:const sepolia "sepolia")
|
||||
(def ^:const goerli "goerli")
|
||||
|
||||
(def ^:const mainnet-chain-ids
|
||||
#{ethereum-mainnet-chain-id arbitrum-mainnet-chain-id optimism-mainnet-chain-id})
|
||||
|
||||
(def ^:const goerli-chain-ids
|
||||
#{ethereum-goerli-chain-id arbitrum-goerli-chain-id optimism-goerli-chain-id})
|
||||
|
||||
(def ^:const sepolia-chain-ids
|
||||
#{ethereum-sepolia-chain-id arbitrum-sepolia-chain-id optimism-sepolia-chain-id})
|
||||
|
||||
|
@ -516,7 +508,6 @@
|
|||
(def ^:const arbitrum-full-name "Arbitrum")
|
||||
|
||||
(def ^:const sepolia-full-name "Sepolia")
|
||||
(def ^:const goerli-full-name "Goerli")
|
||||
|
||||
(def ^:const mainnet-network-name :mainnet)
|
||||
(def ^:const ethereum-network-name :ethereum)
|
||||
|
|
|
@ -22,13 +22,10 @@
|
|||
:raribleMainnetAPIKey config/RARIBLE_MAINNET_API_KEY
|
||||
:raribleTestnetAPIKey config/RARIBLE_TESTNET_API_KEY
|
||||
:alchemyEthereumMainnetToken config/ALCHEMY_ETHEREUM_MAINNET_TOKEN
|
||||
:alchemyEthereumGoerliToken config/ALCHEMY_ETHEREUM_GOERLI_TOKEN
|
||||
:alchemyEthereumSepoliaToken config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN
|
||||
:alchemyOptimismMainnetToken config/ALCHEMY_OPTIMISM_MAINNET_TOKEN
|
||||
:alchemyOptimismGoerliToken config/ALCHEMY_OPTIMISM_GOERLI_TOKEN
|
||||
:alchemyOptimismSepoliaToken config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN
|
||||
:alchemyArbitrumMainnetToken config/ALCHEMY_ARBITRUM_MAINNET_TOKEN
|
||||
:alchemyArbitrumGoerliToken config/ALCHEMY_ARBITRUM_GOERLI_TOKEN
|
||||
:alchemyArbitrumSepoliaToken config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN})
|
||||
|
||||
(defn create
|
||||
|
|
|
@ -50,17 +50,6 @@
|
|||
{:on-success on-success}])
|
||||
:on-cancel nil}]]})))
|
||||
|
||||
(rf/reg-event-fx :profile.settings/toggle-goerli-test-network
|
||||
(fn [{:keys [db]}]
|
||||
(let [value (get-in db [:profile/profile :is-goerli-enabled?])
|
||||
on-success #(rf/dispatch [:logout])]
|
||||
{:fx [[:ui/show-confirmation
|
||||
{:content (i18n/label :t/goerli-testnet-toggle-confirmation)
|
||||
:on-accept #(rf/dispatch [:profile.settings/profile-update :is-goerli-enabled?
|
||||
(not value)
|
||||
{:on-success on-success}])
|
||||
:on-cancel nil}]]})))
|
||||
|
||||
(rf/reg-event-fx :profile.settings/change-preview-privacy
|
||||
(fn [_ [private?]]
|
||||
(let [private?' (boolean private?)]
|
||||
|
|
|
@ -357,8 +357,7 @@
|
|||
{:chain-id chain-id
|
||||
:token-id token-id
|
||||
:contract-address contract-address
|
||||
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
||||
:is-goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])})]
|
||||
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])})]
|
||||
{:fx [[:dispatch
|
||||
[:hide-bottom-sheet]]
|
||||
[:dispatch-later
|
||||
|
@ -377,5 +376,4 @@
|
|||
{:chain-id chain-id
|
||||
:token-id token-id
|
||||
:contract-address contract-address
|
||||
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
||||
:is-goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])})]]]}))
|
||||
:test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])})]]]}))
|
||||
|
|
|
@ -33,17 +33,11 @@
|
|||
(when (> total 1) (str "x" total)))
|
||||
|
||||
(defn- get-opensea-network-name
|
||||
[chain-id test-networks-enabled? is-goerli-enabled?]
|
||||
[chain-id test-networks-enabled?]
|
||||
(let [network-kw (network-utils/id->network chain-id)
|
||||
network-name (name network-kw)
|
||||
mainnet? (= :mainnet network-kw)]
|
||||
(cond (and test-networks-enabled? is-goerli-enabled? mainnet?)
|
||||
(:goerli constants/opensea-url-names)
|
||||
|
||||
(and test-networks-enabled? is-goerli-enabled?)
|
||||
(str network-name "-" (:goerli constants/opensea-url-names))
|
||||
|
||||
(and test-networks-enabled? mainnet?)
|
||||
(cond (and test-networks-enabled? mainnet?)
|
||||
(:sepolia constants/opensea-url-names)
|
||||
|
||||
test-networks-enabled?
|
||||
|
@ -63,11 +57,10 @@
|
|||
|
||||
(defn get-opensea-collectible-url
|
||||
[{:keys [chain-id token-id contract-address
|
||||
test-networks-enabled? is-goerli-enabled?]}]
|
||||
test-networks-enabled?]}]
|
||||
(let [base-link (get-opensea-base-url test-networks-enabled?)
|
||||
opensea-network-name (get-opensea-network-name chain-id
|
||||
test-networks-enabled?
|
||||
is-goerli-enabled?)]
|
||||
test-networks-enabled?)]
|
||||
(str base-link "/assets/" opensea-network-name "/" contract-address "/" token-id)))
|
||||
|
||||
(defn get-collectible-unique-id
|
||||
|
|
|
@ -43,26 +43,4 @@
|
|||
:contract-address contract-address
|
||||
:token-id token-id
|
||||
:test-networks-enabled? true})
|
||||
"https://testnets.opensea.io/assets/optimism-sepolia/0xC/0xT")))
|
||||
(testing "get-opensea-collectible-url goerli"
|
||||
(is (= (utils/get-opensea-collectible-url {:chain-id constants/ethereum-goerli-chain-id
|
||||
:contract-address contract-address
|
||||
:token-id token-id
|
||||
:test-networks-enabled? true
|
||||
:is-goerli-enabled? true})
|
||||
"https://testnets.opensea.io/assets/goerli/0xC/0xT")))
|
||||
(testing "get-opensea-collectible-url goerli arbitrum"
|
||||
(is (= (utils/get-opensea-collectible-url {:chain-id constants/arbitrum-goerli-chain-id
|
||||
:contract-address contract-address
|
||||
:token-id token-id
|
||||
:test-networks-enabled? true
|
||||
:is-goerli-enabled? true})
|
||||
"https://testnets.opensea.io/assets/arbitrum-goerli/0xC/0xT")))
|
||||
|
||||
(testing "get-opensea-collectible-url goerli optimism"
|
||||
(is (= (utils/get-opensea-collectible-url {:chain-id constants/optimism-goerli-chain-id
|
||||
:contract-address contract-address
|
||||
:token-id token-id
|
||||
:test-networks-enabled? true
|
||||
:is-goerli-enabled? true})
|
||||
"https://testnets.opensea.io/assets/optimism-goerli/0xC/0xT"))))
|
||||
"https://testnets.opensea.io/assets/optimism-sepolia/0xC/0xT"))))
|
||||
|
|
|
@ -14,12 +14,6 @@
|
|||
(= chain-id constants/optimism-mainnet-chain-id)
|
||||
config/optimism-mainnet-chain-explorer-link
|
||||
|
||||
(= chain-id constants/ethereum-goerli-chain-id)
|
||||
config/goerli-chain-explorer-link
|
||||
|
||||
(= chain-id constants/optimism-goerli-chain-id)
|
||||
config/optimism-goerli-chain-explorer-link
|
||||
|
||||
(= chain-id constants/ethereum-sepolia-chain-id)
|
||||
config/sepolia-chain-explorer-link
|
||||
|
||||
|
|
|
@ -10,58 +10,42 @@
|
|||
|
||||
(def id->network
|
||||
{constants/ethereum-mainnet-chain-id constants/mainnet-network-name
|
||||
constants/ethereum-goerli-chain-id constants/mainnet-network-name
|
||||
constants/ethereum-sepolia-chain-id constants/mainnet-network-name
|
||||
constants/optimism-mainnet-chain-id constants/optimism-network-name
|
||||
constants/optimism-goerli-chain-id constants/optimism-network-name
|
||||
constants/optimism-sepolia-chain-id constants/optimism-network-name
|
||||
constants/arbitrum-mainnet-chain-id constants/arbitrum-network-name
|
||||
constants/arbitrum-goerli-chain-id constants/arbitrum-network-name
|
||||
constants/arbitrum-sepolia-chain-id constants/arbitrum-network-name})
|
||||
|
||||
(defn- get-chain-id
|
||||
[{:keys [mainnet-chain-id sepolia-chain-id goerli-chain-id testnet-enabled? goerli-enabled?]}]
|
||||
(cond
|
||||
(and testnet-enabled? goerli-enabled?)
|
||||
goerli-chain-id
|
||||
|
||||
testnet-enabled?
|
||||
[{:keys [mainnet-chain-id sepolia-chain-id testnet-enabled?]}]
|
||||
(if testnet-enabled?
|
||||
sepolia-chain-id
|
||||
|
||||
:else
|
||||
mainnet-chain-id))
|
||||
|
||||
(defn network->chain-id
|
||||
([db network]
|
||||
(let [{:keys [test-networks-enabled? is-goerli-enabled?]} (:profile/profile db)]
|
||||
(let [{:keys [test-networks-enabled?]} (:profile/profile db)]
|
||||
(network->chain-id {:network network
|
||||
:testnet-enabled? test-networks-enabled?
|
||||
:goerli-enabled? is-goerli-enabled?})))
|
||||
([{:keys [network testnet-enabled? goerli-enabled?]}]
|
||||
:testnet-enabled? test-networks-enabled?})))
|
||||
([{:keys [network testnet-enabled?]}]
|
||||
(condp contains? (keyword network)
|
||||
#{constants/mainnet-network-name (keyword constants/mainnet-short-name)}
|
||||
(get-chain-id
|
||||
{:mainnet-chain-id constants/ethereum-mainnet-chain-id
|
||||
:sepolia-chain-id constants/ethereum-sepolia-chain-id
|
||||
:goerli-chain-id constants/ethereum-goerli-chain-id
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?})
|
||||
:testnet-enabled? testnet-enabled?})
|
||||
|
||||
#{constants/optimism-network-name (keyword constants/optimism-short-name)}
|
||||
(get-chain-id
|
||||
{:mainnet-chain-id constants/optimism-mainnet-chain-id
|
||||
:sepolia-chain-id constants/optimism-sepolia-chain-id
|
||||
:goerli-chain-id constants/optimism-goerli-chain-id
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?})
|
||||
:testnet-enabled? testnet-enabled?})
|
||||
|
||||
#{constants/arbitrum-network-name (keyword constants/arbitrum-short-name)}
|
||||
(get-chain-id
|
||||
{:mainnet-chain-id constants/arbitrum-mainnet-chain-id
|
||||
:sepolia-chain-id constants/arbitrum-sepolia-chain-id
|
||||
:goerli-chain-id constants/arbitrum-goerli-chain-id
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?}))))
|
||||
:testnet-enabled? testnet-enabled?}))))
|
||||
|
||||
(defn network-list
|
||||
[{:keys [balances-per-chain]} networks]
|
||||
|
@ -82,19 +66,13 @@
|
|||
(network-list $ networks)))
|
||||
|
||||
(defn get-default-chain-ids-by-mode
|
||||
[{:keys [test-networks-enabled? is-goerli-enabled?]}]
|
||||
(cond
|
||||
(and test-networks-enabled? is-goerli-enabled?)
|
||||
constants/goerli-chain-ids
|
||||
|
||||
test-networks-enabled?
|
||||
[{:keys [test-networks-enabled?]}]
|
||||
(if test-networks-enabled?
|
||||
constants/sepolia-chain-ids
|
||||
|
||||
:else
|
||||
constants/mainnet-chain-ids))
|
||||
|
||||
(defn resolve-receiver-networks
|
||||
[{:keys [prefix testnet-enabled? goerli-enabled?]}]
|
||||
[{:keys [prefix testnet-enabled?]}]
|
||||
(let [prefix (if (string/blank? prefix)
|
||||
constants/default-multichain-address-prefix
|
||||
prefix)
|
||||
|
@ -104,8 +82,7 @@
|
|||
(mapv
|
||||
#(network->chain-id
|
||||
{:network %
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?})))))
|
||||
:testnet-enabled? testnet-enabled?})))))
|
||||
|
||||
(def network->short-name
|
||||
{constants/mainnet-network-name constants/mainnet-short-name
|
||||
|
@ -185,16 +162,13 @@
|
|||
[chain-id]
|
||||
(as-> chain-id $
|
||||
(condp contains? $
|
||||
#{constants/ethereum-mainnet-chain-id constants/ethereum-goerli-chain-id
|
||||
constants/ethereum-sepolia-chain-id}
|
||||
#{constants/ethereum-mainnet-chain-id constants/ethereum-sepolia-chain-id}
|
||||
mainnet-network-details
|
||||
|
||||
#{constants/arbitrum-mainnet-chain-id constants/arbitrum-goerli-chain-id
|
||||
constants/arbitrum-sepolia-chain-id}
|
||||
#{constants/arbitrum-mainnet-chain-id constants/arbitrum-sepolia-chain-id}
|
||||
arbitrum-network-details
|
||||
|
||||
#{constants/optimism-mainnet-chain-id constants/optimism-goerli-chain-id
|
||||
constants/optimism-sepolia-chain-id}
|
||||
#{constants/optimism-mainnet-chain-id constants/optimism-sepolia-chain-id}
|
||||
optimism-network-details
|
||||
|
||||
nil)
|
||||
|
|
|
@ -6,19 +6,17 @@
|
|||
|
||||
(deftest network->chain-id-test
|
||||
(testing "network->chain-id function"
|
||||
(is (= (utils/network->chain-id {:network :mainnet :testnet-enabled? false :goerli-enabled? false})
|
||||
(is (= (utils/network->chain-id {:network :mainnet :testnet-enabled? false})
|
||||
constants/ethereum-mainnet-chain-id))
|
||||
(is (= (utils/network->chain-id {:network :eth :testnet-enabled? true :goerli-enabled? false})
|
||||
(is (= (utils/network->chain-id {:network :eth :testnet-enabled? true})
|
||||
constants/ethereum-sepolia-chain-id))
|
||||
(is (= (utils/network->chain-id {:network "optimism" :testnet-enabled? true :goerli-enabled? false})
|
||||
(is (= (utils/network->chain-id {:network "optimism" :testnet-enabled? true})
|
||||
constants/optimism-sepolia-chain-id))
|
||||
(is (= (utils/network->chain-id {:network "oeth" :testnet-enabled? false :goerli-enabled? true})
|
||||
(is (= (utils/network->chain-id {:network "oeth" :testnet-enabled? false})
|
||||
constants/optimism-mainnet-chain-id))
|
||||
(is (= (utils/network->chain-id {:network :oeth :testnet-enabled? true :goerli-enabled? true})
|
||||
constants/optimism-goerli-chain-id))
|
||||
(is (= (utils/network->chain-id {:network :arb1 :testnet-enabled? false :goerli-enabled? false})
|
||||
(is (= (utils/network->chain-id {:network :arb1 :testnet-enabled? false})
|
||||
constants/arbitrum-mainnet-chain-id))
|
||||
(is (= (utils/network->chain-id {:network :arbitrum :testnet-enabled? true :goerli-enabled? false})
|
||||
(is (= (utils/network->chain-id {:network :arbitrum :testnet-enabled? true})
|
||||
constants/arbitrum-sepolia-chain-id))))
|
||||
|
||||
(deftest short-names->network-preference-prefix-test
|
||||
|
|
|
@ -502,10 +502,8 @@
|
|||
(for [[k v] chains :when (= v "down")] k))
|
||||
keys)
|
||||
test-networks-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
||||
is-goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])
|
||||
chain-ids-by-mode (network-utils/get-default-chain-ids-by-mode
|
||||
{:test-networks-enabled? test-networks-enabled?
|
||||
:is-goerli-enabled? is-goerli-enabled?})
|
||||
{:test-networks-enabled? test-networks-enabled?})
|
||||
chains-filtered-by-mode (remove #(not (contains? chain-ids-by-mode %)) down-chain-ids)
|
||||
chains-down? (and (network.data-store/online? db) (seq chains-filtered-by-mode))
|
||||
chain-names (when chains-down?
|
||||
|
@ -518,8 +516,7 @@
|
|||
(when (seq down-chain-ids)
|
||||
(log/info "[wallet] Chain(s) down: " down-chain-ids)
|
||||
(log/info "[wallet] Chain name(s) down: " chain-names)
|
||||
(log/info "[wallet] Test network enabled: " (boolean test-networks-enabled?))
|
||||
(log/info "[wallet] Goerli network enabled: " (boolean is-goerli-enabled?)))
|
||||
(log/info "[wallet] Test network enabled: " (boolean test-networks-enabled?)))
|
||||
|
||||
;; NOTE <shivekkhurana>: We used to show an error toast, but disabled it because the down
|
||||
;; signal is sent randomly. Needs to be investigated and enabled again !
|
||||
|
|
|
@ -152,11 +152,9 @@
|
|||
(fn [{:keys [db]} [{:keys [address recipient stack-id start-flow?]}]]
|
||||
(let [[prefix to-address] (utils/split-prefix-and-address address)
|
||||
testnet-enabled? (get-in db [:profile/profile :test-networks-enabled?])
|
||||
goerli-enabled? (get-in db [:profile/profile :is-goerli-enabled?])
|
||||
receiver-networks (network-utils/resolve-receiver-networks
|
||||
{:prefix prefix
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?})
|
||||
:testnet-enabled? testnet-enabled?})
|
||||
collectible-tx? (send-utils/tx-type-collectible?
|
||||
(-> db :wallet :ui :send :tx-type))
|
||||
collectible (when collectible-tx?
|
||||
|
|
|
@ -357,11 +357,9 @@
|
|||
(testing "testing when collectible balance is more than 1"
|
||||
(let [collectible (collectible-with-balance 2)
|
||||
testnet-enabled? false
|
||||
goerli-enabled? false
|
||||
receiver-networks (network-utils/resolve-receiver-networks
|
||||
{:prefix prefix
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?})
|
||||
:testnet-enabled? testnet-enabled?})
|
||||
expected-result {:db {:wallet {:ui {:send {:other-props :value
|
||||
:recipient recipient
|
||||
:to-address to-address
|
||||
|
@ -371,8 +369,7 @@
|
|||
:receiver-networks receiver-networks
|
||||
:tx-type tx-type
|
||||
:collectible collectible}}}
|
||||
:profile/profile {:test-networks-enabled? false
|
||||
:is-goerli-enabled? false}}
|
||||
:profile/profile {:test-networks-enabled? false}}
|
||||
:fx [nil
|
||||
[:dispatch
|
||||
[:wallet/wizard-navigate-forward
|
||||
|
@ -383,8 +380,7 @@
|
|||
{:wallet {:ui {:send {:other-props :value
|
||||
:tx-type tx-type
|
||||
:collectible collectible}}}
|
||||
:profile/profile {:test-networks-enabled? testnet-enabled?
|
||||
:is-goerli-enabled? goerli-enabled?}})
|
||||
:profile/profile {:test-networks-enabled? testnet-enabled?}})
|
||||
(is (match? expected-result
|
||||
(dispatch [event-id
|
||||
{:address address
|
||||
|
@ -394,11 +390,9 @@
|
|||
(testing "testing when collectible balance is 1"
|
||||
(let [collectible (collectible-with-balance 1)
|
||||
testnet-enabled? false
|
||||
goerli-enabled? false
|
||||
receiver-networks (network-utils/resolve-receiver-networks
|
||||
{:prefix prefix
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?})
|
||||
:testnet-enabled? testnet-enabled?})
|
||||
expected-result {:db {:wallet {:ui {:send {:other-props :value
|
||||
:recipient recipient
|
||||
:to-address to-address
|
||||
|
@ -408,8 +402,7 @@
|
|||
:receiver-networks receiver-networks
|
||||
:tx-type tx-type
|
||||
:collectible collectible}}}
|
||||
:profile/profile {:test-networks-enabled? false
|
||||
:is-goerli-enabled? false}}
|
||||
:profile/profile {:test-networks-enabled? false}}
|
||||
:fx [[:dispatch [:wallet/start-get-suggested-routes {:amount 1}]]
|
||||
[:dispatch
|
||||
[:wallet/wizard-navigate-forward
|
||||
|
@ -420,8 +413,7 @@
|
|||
{:wallet {:ui {:send {:other-props :value
|
||||
:tx-type tx-type
|
||||
:collectible collectible}}}
|
||||
:profile/profile {:test-networks-enabled? testnet-enabled?
|
||||
:is-goerli-enabled? goerli-enabled?}})
|
||||
:profile/profile {:test-networks-enabled? testnet-enabled?}})
|
||||
(is (match? expected-result
|
||||
(dispatch [event-id
|
||||
{:address address
|
||||
|
|
|
@ -29,7 +29,6 @@
|
|||
(update network :full-name #(str % " " testnet-name)))]
|
||||
(condp #(contains? %1 %2) (:chain-id network)
|
||||
constants/sepolia-chain-ids (add-testnet-name constants/sepolia-full-name)
|
||||
constants/goerli-chain-ids (add-testnet-name constants/goerli-full-name)
|
||||
network)))
|
||||
|
||||
(defn chain-id->network-details
|
||||
|
@ -47,7 +46,7 @@
|
|||
js/parseInt))
|
||||
chains))]
|
||||
(if testnet-mode?
|
||||
(set/subset? chain-ids (set/union constants/sepolia-chain-ids constants/goerli-chain-ids))
|
||||
(set/subset? chain-ids constants/sepolia-chain-ids)
|
||||
(set/subset? chain-ids constants/mainnet-chain-ids))))
|
||||
|
||||
(defn get-proposal-networks
|
||||
|
|
|
@ -136,12 +136,6 @@
|
|||
(fn [profile]
|
||||
(:universal-profile-url profile)))
|
||||
|
||||
(re-frame/reg-sub
|
||||
:profile/is-goerli-enabled?
|
||||
:<- [:profile/profile]
|
||||
(fn [profile]
|
||||
(:is-goerli-enabled? profile)))
|
||||
|
||||
(re-frame/reg-sub
|
||||
:profile/peer-syncing-enabled?
|
||||
:<- [:profile/profile]
|
||||
|
|
|
@ -253,12 +253,10 @@
|
|||
:wallet/selected-networks->chain-ids
|
||||
:<- [:wallet/selected-networks]
|
||||
:<- [:profile/test-networks-enabled?]
|
||||
:<- [:profile/is-goerli-enabled?]
|
||||
(fn [[selected-networks testnet-enabled? goerli-enabled?]]
|
||||
(fn [[selected-networks testnet-enabled?]]
|
||||
(set (map #(network-utils/network->chain-id
|
||||
{:network %
|
||||
:testnet-enabled? testnet-enabled?
|
||||
:goerli-enabled? goerli-enabled?})
|
||||
:testnet-enabled? testnet-enabled?})
|
||||
selected-networks))))
|
||||
|
||||
(defn- format-settings-keypair-accounts
|
||||
|
|
|
@ -122,10 +122,6 @@
|
|||
:ens-name "test.eth"
|
||||
:chain-id constants/ethereum-mainnet-chain-id
|
||||
:expected-result "0xeefb13c7d42efcc655e528da6d6f7bbcf9a2251d"}
|
||||
{:description "Test on Goerli testnet"
|
||||
:ens-name "qoqobolo.stateofus.eth"
|
||||
:chain-id constants/ethereum-goerli-chain-id
|
||||
:expected-result "0xf8f4f6b5c73f4fb561eb2676326d81b7aba180b0"}
|
||||
{:description "Test on Sepolia testnet"
|
||||
:ens-name "code.eth"
|
||||
:chain-id constants/ethereum-sepolia-chain-id
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
;; this is the addresses of ens registries for the different networks
|
||||
(def ens-registries
|
||||
{:mainnet "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"
|
||||
:goerli "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"})
|
||||
:sepolia "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"})
|
||||
|
||||
(def default-address "0x0000000000000000000000000000000000000000")
|
||||
(def default-key
|
||||
|
|
|
@ -26,15 +26,6 @@
|
|||
(when (and name (string/ends-with? name domain))
|
||||
(first (string/split name "."))))
|
||||
|
||||
(def old-registrars
|
||||
(merge
|
||||
{:mainnet "0xDB5ac1a559b02E12F29fC0eC0e37Be8E046DEF49"
|
||||
:goerli "0xD1f7416F91E7Eb93dD96A61F12FC092aD6B67B11"}))
|
||||
|
||||
(defn get-cached-registrar
|
||||
[chain]
|
||||
(get old-registrars chain))
|
||||
|
||||
(defn lower-case?
|
||||
[s]
|
||||
(when s
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
(def chains
|
||||
{:mainnet {:id 1 :name "Mainnet"}
|
||||
:xdai {:id 100 :name "xDai"}
|
||||
:goerli {:id 5 :name "Goerli"}
|
||||
:sepolia {:id 11155111 :name "Sepolia"}
|
||||
:bsc {:id BSC-mainnet-chain-id
|
||||
:name "BSC"}
|
||||
:bsc-testnet {:id BSC-testnet-chain-id
|
||||
|
@ -37,7 +37,7 @@
|
|||
|
||||
(defn testnet?
|
||||
[id]
|
||||
(contains? #{(chain-keyword->chain-id :goerli)
|
||||
(contains? #{(chain-keyword->chain-id :sepolia)
|
||||
(chain-keyword->chain-id :bsc-testnet)}
|
||||
id))
|
||||
|
||||
|
|
|
@ -6,18 +6,18 @@
|
|||
(defn chain-ids-db
|
||||
[test-networks-enabled?]
|
||||
{:profile/profile {:test-networks-enabled? test-networks-enabled?}
|
||||
:wallet {:networks {:test [{:chain-id 3}
|
||||
{:chain-id 4}
|
||||
{:chain-id 5}]
|
||||
:wallet {:networks {:test [{:chain-id 11155111}
|
||||
{:chain-id 421614}
|
||||
{:chain-id 11155420}]
|
||||
:prod [{:chain-id 1}
|
||||
{:chain-id 42161}
|
||||
{:chain-id 10}]}}})
|
||||
|
||||
(deftest chain-id->chain-keyword-test
|
||||
(is (= (chain/chain-id->chain-keyword 1) :mainnet))
|
||||
(is (= (chain/chain-id->chain-keyword 5) :goerli))
|
||||
(is (= (chain/chain-id->chain-keyword 11155111) :sepolia))
|
||||
(is (= (chain/chain-id->chain-keyword 5777) :custom)))
|
||||
|
||||
(deftest chain-ids-test
|
||||
(is (= (chain/chain-ids (chain-ids-db false)) [1 42161 10]))
|
||||
(is (= (chain/chain-ids (chain-ids-db true)) [3 4 5])))
|
||||
(is (= (chain/chain-ids (chain-ids-db true)) [11155111 421614 11155420])))
|
||||
|
|
|
@ -111,9 +111,9 @@
|
|||
:name "Status Network Token"
|
||||
:symbol :SNT
|
||||
:decimals 18}}
|
||||
:goerli {"0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"
|
||||
:sepolia {"0xE452027cdEF746c7Cd3DB31CB700428b16cD8E51"
|
||||
{:address
|
||||
"0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"
|
||||
"0xE452027cdEF746c7Cd3DB31CB700428b16cD8E51"
|
||||
:name "Status Test Token"
|
||||
:symbol :STT
|
||||
:decimals 18}}})
|
||||
|
|
|
@ -1103,7 +1103,6 @@
|
|||
"glossary": "Glossary",
|
||||
"go-to": "Go to",
|
||||
"go-to-settings": "Go to Settings...",
|
||||
"goerli-testnet-toggle-confirmation": "Are you sure you want to toggle Goerli? This will log you out and you will have to login again.",
|
||||
"got-it": "Got it",
|
||||
"grant-face-id-permissions": "To grant the required Face ID permission, please go to your system settings and make sure that Status > Face ID is selected",
|
||||
"grant-fingerprints-permissions": "To grant the required fingerprints permission, please go to your system settings and make sure that Status > Fingerprints is selected",
|
||||
|
|
Loading…
Reference in New Issue