From 995bc58791ddbb59e9b3d0d75c11c1c058e24071 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mart=C3=ADn=20Ra=C3=BAl=20Villalba?= Date: Fri, 25 Sep 2020 12:27:50 -0300 Subject: [PATCH] Add Binance Smart Chain (BSC) support --- src/js/index.js | 8 ++++++++ tests/spec/tests.js | 10 ++++++++++ 2 files changed, 18 insertions(+) diff --git a/src/js/index.js b/src/js/index.js index 252eec1..cd3f769 100644 --- a/src/js/index.js +++ b/src/js/index.js @@ -1887,6 +1887,7 @@ || (name == "ESN - Ethersocial Network") || (name == "VET - VeChain") || (name == "ERE - EtherCore") + || (name == "BSC - Binance Smart Chain") } function networkIsRsk() { @@ -2232,6 +2233,13 @@ setHdCoin(183); }, }, + { + name: "BSC - Binance Smart Chain", + onSelect: function() { + network = libs.bitcoin.networks.bitcoin; + setHdCoin(60); + }, + }, { name: "BSV - BitcoinSV", onSelect: function() { diff --git a/tests/spec/tests.js b/tests/spec/tests.js index 14cdb8e..73e3087 100644 --- a/tests/spec/tests.js +++ b/tests/spec/tests.js @@ -2275,6 +2275,16 @@ it('Allows selection of Scribe', function(done) { }; testNetwork(done, params); }); +it('Allows selection of Binance Smart Chain', function(done) { + var params = { + selectText: "BSC - Binance Smart Chain", + phrase: "abandon abandon ability", + firstAddress: "0xe5815d5902Ad612d49283DEdEc02100Bd44C2772", + firstPubKey: "0x03e723e5b3aa7d72213f01139aa4783e1b34f74e1a04534e3fd8e29bfe2768af8a", + firstPrivKey: "0x8f253078b73d7498302bb78c171b23ce7a8fb511987d2b2702b731638a4a15e7", + }; + testNetwork(done, params); +}); // BIP39 seed is set from phrase it('Sets the bip39 seed from the prhase', function(done) { -- 2.41.0