aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorIan Coleman <ian@iancoleman.io>2018-05-29 09:22:14 +1000
committerIan Coleman <ian@iancoleman.io>2018-05-29 11:30:48 +1000
commit530648c174dc295b47c22db7df4ea6753273efa6 (patch)
treeac1adbfb1de01f904a57f6f8145207ac4ca70104 /tests
parentc147cb5e4f40297c2377ecb5b03975b3f04d75bd (diff)
downloadBIP39-530648c174dc295b47c22db7df4ea6753273efa6.tar.gz
BIP39-530648c174dc295b47c22db7df4ea6753273efa6.tar.zst
BIP39-530648c174dc295b47c22db7df4ea6753273efa6.zip
Add litecoin segwit tests
Diffstat (limited to 'tests')
-rw-r--r--tests/spec/tests.js38
1 files changed, 38 insertions, 0 deletions
diff --git a/tests/spec/tests.js b/tests/spec/tests.js
index 94fc672..5ddd686 100644
--- a/tests/spec/tests.js
+++ b/tests/spec/tests.js
@@ -3643,4 +3643,42 @@ it('Does not show a warning if entropy is stronger than mnemonic length', functi
3643 }); 3643 });
3644}); 3644});
3645 3645
3646it('Shows a warning for litecoin BIP84 (which does not have p2wpkh params)', function(done) {
3647 driver.findElement(By.css('.phrase'))
3648 .sendKeys('abandon abandon ability');
3649 selectNetwork("LTC - Litecoin");
3650 driver.findElement(By.css('#bip84-tab a'))
3651 .click()
3652 // bip84 unavailable is shown
3653 driver.sleep(feedbackDelay).then(function() {
3654 driver.findElement(By.css('#bip84 .unavailable'))
3655 .getAttribute("class")
3656 .then(function(classes) {
3657 expect(classes).not.toContain("hidden");
3658 done();
3659 });
3660 });
3661});
3662
3663it('Shows litecoin BIP49 addresses', function(done) {
3664 driver.findElement(By.css('.phrase'))
3665 .sendKeys('abandon abandon ability');
3666 selectNetwork("LTC - Litecoin");
3667 driver.findElement(By.css('#bip49-tab a'))
3668 .click()
3669 // bip49 addresses are shown
3670 driver.sleep(generateDelay).then(function() {
3671 driver.findElement(By.css('#bip49 .available'))
3672 .getAttribute("class")
3673 .then(function(classes) {
3674 expect(classes).not.toContain("hidden");
3675 // check first address
3676 getFirstAddress(function(address) {
3677 expect(address).toBe("MFwLPhsXoBuSLL8cLmW9uK6tChkzduV8qN");
3678 done();
3679 });
3680 });
3681 });
3682});
3683
3646}); 3684});