From 20a9e349d1af3d351efa5a8b1a55d9fd75d43f31 Mon Sep 17 00:00:00 2001 From: Andrew Drake Date: Thu, 12 Aug 2010 00:08:30 -0700 Subject: [PATCH] [JAEGER] Fix tests regressed by debug mode. r=dvander --- js/src/tests/e4x/decompilation/regress-429249.js | 3 ++- js/src/tests/ecma_3/extensions/regress-429248.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/js/src/tests/e4x/decompilation/regress-429249.js b/js/src/tests/e4x/decompilation/regress-429249.js index 771546a129a..c3f9c9fa893 100644 --- a/js/src/tests/e4x/decompilation/regress-429249.js +++ b/js/src/tests/e4x/decompilation/regress-429249.js @@ -53,8 +53,9 @@ expect = 'function g() { return ; }'; actual = g + ''; compareSource(expect, actual, summary + ' : before trap'); -if (typeof trap == 'function') +if (typeof trap == 'function' && typeof setDebug == 'function') { + setDebug(true); trap(g, 0, ""); actual = g + ''; compareSource(expect, actual, summary + ' : after trap'); diff --git a/js/src/tests/ecma_3/extensions/regress-429248.js b/js/src/tests/ecma_3/extensions/regress-429248.js index 31f656c60f9..949cd19a8e3 100644 --- a/js/src/tests/ecma_3/extensions/regress-429248.js +++ b/js/src/tests/ecma_3/extensions/regress-429248.js @@ -54,8 +54,9 @@ function test() function c() { do{}while(0) } - if (typeof trap == 'function') + if (typeof trap == 'function' && typeof setDebug == 'function') { + setDebug(true); trap(c, 0, ""); } c + '';