Merge branch 'master' into master
authoriancoleman <1281387+iancoleman@users.noreply.github.com>
Tue, 4 Dec 2018 21:36:51 +0000 (08:36 +1100)
committerGitHub <noreply@github.com>
Tue, 4 Dec 2018 21:36:51 +0000 (08:36 +1100)
1  2 
src/js/bitcoinjs-extensions.js
src/js/index.js
tests/spec/tests.js

index d1073aad0f346c1be51f67f2c9ea6bcc19e5d32f,bd96e053235525eb58165fda826c87e5af69957e..5ba584ea040cb477cee5ba4ea80d7872c3295c31
@@@ -1067,17 -1067,6 +1067,17 @@@ bitcoinjs.bitcoin.networks.rubycoin = 
    wif: 0xbc,
  };
  
 +bitcoinjs.bitcoin.networks.safecoin = {
 +  messagePrefix: '\x18Safecoin Signed Message:\n',
 +  bip32: {
 +    public: 0x0488b21e,
 +    private: 0x0488ade4,
 +  },
 +  pubKeyHash: 0x3d,
 +  scriptHash: 0x56,
 +  wif: 0xbd,
 +};
 +
  bitcoinjs.bitcoin.networks.salus = {
  messagePrefix: '\x18Salus Signed Message:\n',
  bip32: {
@@@ -1441,3 -1430,25 +1441,25 @@@ bitcoinjs.bitcoin.networks.phore = 
    scriptHash: 0x0D,
    wif:  0xD4,
  };
+ bitcoinjs.bitcoin.networks.blocknode = {
+   messagePrefix: '\x18Blocknode Signed Message:\n',
+   bip32: {
+       public: 0x0488b21e,
+       private: 0x0488ade4
+   },
+   pubKeyHash: 0x19,
+   scriptHash: 0x3F,
+   wif:  0x4b,
+ };
+ bitcoinjs.bitcoin.networks.blocknode_testnet = {
+   messagePrefix: '\x18Blocknode Testnet Signed Message:\n',
+   bip32: {
+       public: 0x043587cf,
+       private: 0x04358394
+   },
+   pubKeyHash: 0x55,
+   scriptHash: 0x7d,
+   wif:  0x89,
+ };
diff --combined src/js/index.js
index 6b292f53095f80ebf56a63fba07c74fa7a911233,0dd23f39460211fc5e6e0bcc4db4c06738ab358a..83221154ab90543c487aa3e00de51baf6e549891
                  setHdCoin(10);
              },
          },
+         {
+             name: "BND - Blocknode",
+             onSelect: function() {
+                 network = bitcoinjs.bitcoin.networks.blocknode;
+                 setHdCoin(2941);
+             },
+         },    
+               {
+             name: "tBND - Blocknode Testnet",
+             onSelect: function() {
+                 network = bitcoinjs.bitcoin.networks.blocknode_testnet;
+                 setHdCoin(1);
+             },
+         },
          {
              name: "BRIT - Britcoin",
              onSelect: function() {
              },
          },
          {
 +          name: "SAFE - Safecoin",
 +          onSelect: function() {
 +              network = bitcoinjs.bitcoin.networks.safecoin;
 +              setHdCoin(19165);
 +            },
 +        },
 +      {
            name: "SLS - Salus",
            onSelect: function() {
                network = bitcoinjs.bitcoin.networks.salus;
diff --combined tests/spec/tests.js
index 58662fd86abc5d34002ffb78d648c1bb06b073da,cd3f381d1aba6284e049c12ebedc44984b88a1ef..0bb56f8ac6affee7b49ddcd9ca4f157a140eae73
@@@ -1355,14 -1355,21 +1355,28 @@@ it('Allows selection of Phore', functio
      };
      testNetwork(done, params);
  });
-     
 +it('Allows selection of Safecoin', function(done) {
 +     var params = {
 +         selectText: "SAFE - Safecoin",
 +         firstAddress: "RmV56kPW7jeCmDA8sukHwbR7RZSbg9NFNF",
 +     };
 +     testNetwork(done, params);
 + });
+ it('Allows selection of Blocknode', function(done) {
+     var params = {
+         selectText: "BND - Blocknode",
+         firstAddress: "BG8xZSAur2jYLG9VXt8dYfkKxxeR7w9bSe",
+     };
+     testNetwork(done, params);
+ });
+ it('Allows selection of Blocknode Testnet', function(done) {
+     var params = {
+         selectText: "tBND - Blocknode Testnet",
+         firstAddress: "bSptsFyDktFSKpWveRywJsDoJA2TC6qfHv",
+     };
+     testNetwork(done, params);
+ });
  // BIP39 seed is set from phrase
  it('Sets the bip39 seed from the prhase', function(done) {
      driver.findElement(By.css('.phrase'))