diff --git a/node/node-0.11-tests.ts b/node/node-0.11-tests.ts index 92ce84a9d8..aacfdde54d 100644 --- a/node/node-0.11-tests.ts +++ b/node/node-0.11-tests.ts @@ -24,7 +24,7 @@ assert.notStrictEqual(2, "2", "uses === comparator"); assert.throws(() => { throw "a hammer at your face"; }, undefined, "DODGED IT"); assert.doesNotThrow(() => { - if (false) { throw "a hammer at your face"; } + if (Math.random() < 0.5) { throw "a hammer at your face"; } }, undefined, "What the...*crunch*"); //////////////////////////////////////////////////// diff --git a/node/node-0.12-tests.ts b/node/node-0.12-tests.ts index f955421d96..53eff3121f 100644 --- a/node/node-0.12-tests.ts +++ b/node/node-0.12-tests.ts @@ -26,7 +26,7 @@ assert.notStrictEqual(2, "2", "uses === comparator"); assert.throws(() => { throw "a hammer at your face"; }, undefined, "DODGED IT"); assert.doesNotThrow(() => { - if (false) { throw "a hammer at your face"; } + if (Math.random() < 0.5) { throw "a hammer at your face"; } }, undefined, "What the...*crunch*"); //////////////////////////////////////////////////// diff --git a/node/node-tests.ts b/node/node-tests.ts index 1d0a321c63..0bb6635377 100644 --- a/node/node-tests.ts +++ b/node/node-tests.ts @@ -32,7 +32,7 @@ assert.notDeepStrictEqual({ x: { y: "3" } }, { x: { y: 3 } }, "uses === comparat assert.throws(() => { throw "a hammer at your face"; }, undefined, "DODGED IT"); assert.doesNotThrow(() => { - if (false) { throw "a hammer at your face"; } + if (Math.random() < 0.5) { throw "a hammer at your face"; } }, undefined, "What the...*crunch*"); ////////////////////////////////////////////////////