aboutsummaryrefslogtreecommitdiff
path: root/tests.js
diff options
context:
space:
mode:
Diffstat (limited to 'tests.js')
-rw-r--r--tests.js30
1 files changed, 30 insertions, 0 deletions
diff --git a/tests.js b/tests.js
index d55b8f4..49d42c3 100644
--- a/tests.js
+++ b/tests.js
@@ -571,6 +571,36 @@ page.open(url, function(status) {
571}); 571});
572}, 572},
573 573
574// Network can be set to game
575function() {
576page.open(url, function(status) {
577 // set the phrase and coin
578 var expected = "GSMY9bAp36cMR4zyT4uGVS7GFjpdXbao5Q";
579 page.evaluate(function() {
580 $(".phrase").val("abandon abandon ability");
581 $(".phrase").trigger("input");
582 $(".network option[selected]").removeAttr("selected");
583 $(".network option").filter(function() {
584 return $(this).html() == "GAME";
585 }).prop("selected", true);
586 $(".network").trigger("change");
587 });
588 // check the address is generated correctly
589 waitForGenerate(function() {
590 var actual = page.evaluate(function() {
591 return $(".address:first").text();
592 });
593 if (actual != expected) {
594 console.log("GAME address is incorrect");
595 console.log("Expected: " + expected);
596 console.log("Actual: " + actual);
597 fail();
598 }
599 next();
600 });
601});
602},
603
574// Network can be set to namecoin 604// Network can be set to namecoin
575function() { 605function() {
576page.open(url, function(status) { 606page.open(url, function(status) {