diff --git a/js/test.js b/js/test.js index c3d518d6..e5dba698 100644 --- a/js/test.js +++ b/js/test.js @@ -14,6 +14,9 @@ * along with this program. If not, see . */ +mocha.setup("bdd"); +window.assert = chai.assert; + describe("ArrayBuffer->String conversion", function() { it('works', function() { var b = new ArrayBuffer(3); @@ -137,9 +140,9 @@ describe("Curve25519", function() { // this is a just cute little trick to get a nice-looking note about // which curve25519 impl we're using. if (window.textsecure.nacl.USE_NACL) { - it("is NACL"); + it("is NACL", function(done) { done(); }); } else { - it("is JavaScript"); + it("is JavaScript", function(done) { done(); }); } }); @@ -395,3 +398,8 @@ describe("Axolotl", function() { }); }); }); + +if (window.mochaPhantomJS) + mochaPhantomJS.run(); +else + mocha.run(); diff --git a/test.html b/test.html index ed5dbda0..b83becff 100644 --- a/test.html +++ b/test.html @@ -19,11 +19,11 @@ +

Run this out of the chrome-plugin:// namespace (and expect plugin state to be cleared/corrupted), not file://

+
-

Run this out of the chrome-plugin:// namespace (and expect plugin state to be cleared/corrupted), not file://

-
@@ -31,10 +31,6 @@ - @@ -62,12 +58,5 @@ - -