aboutsummaryrefslogtreecommitdiff
path: root/tests.js
diff options
context:
space:
mode:
authorIan Coleman <coleman.ian@gmail.com>2016-11-07 16:56:44 +1100
committerIan Coleman <coleman.ian@gmail.com>2016-11-07 16:56:44 +1100
commit425b75a925717eb6f9813503569592a8160c5f34 (patch)
tree3dcc83e4c88b0a68eaff3bc1724c07093608e4e5 /tests.js
parentadc8ce127d4f8ea0d7e5ede6a82c2791d60ff4d2 (diff)
downloadBIP39-425b75a925717eb6f9813503569592a8160c5f34.tar.gz
BIP39-425b75a925717eb6f9813503569592a8160c5f34.tar.zst
BIP39-425b75a925717eb6f9813503569592a8160c5f34.zip
Dice entropy conversion to Base 6 is simpler
Old: Every dice roll is reduced by 1 New: Replace all 6s with 0s
Diffstat (limited to 'tests.js')
-rw-r--r--tests.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests.js b/tests.js
index 8de6391..809162c 100644
--- a/tests.js
+++ b/tests.js
@@ -2072,7 +2072,7 @@ page.open(url, function(status) {
2072 // dice entropy is converted to base6 2072 // dice entropy is converted to base6
2073 try { 2073 try {
2074 e = Entropy.fromString("123456"); 2074 e = Entropy.fromString("123456");
2075 if (e.cleanStr != "012345") { 2075 if (e.cleanStr != "123450") {
2076 return "Dice entropy is not automatically converted to base6"; 2076 return "Dice entropy is not automatically converted to base6";
2077 } 2077 }
2078 } 2078 }
@@ -2444,7 +2444,7 @@ page.open(url, function(status) {
2444 var entropyText = page.evaluate(function() { 2444 var entropyText = page.evaluate(function() {
2445 return $(".entropy-container").text(); 2445 return $(".entropy-container").text();
2446 }); 2446 });
2447 if (entropyText.indexOf("012345") == -1) { 2447 if (entropyText.indexOf("123450") == -1) {
2448 console.log("Dice entropy is not shown to user as base 6 value"); 2448 console.log("Dice entropy is not shown to user as base 6 value");
2449 fail(); 2449 fail();
2450 } 2450 }