Bug 670831 - Enable some mochitest sanity tests for uncaught exception handling. r=jmaher
authorCameron McCormack <cam@mcc.id.au>
Fri, 02 Dec 2011 23:25:04 +1100
changeset 82806 8b4e1c66eab6ec634d4c8095bd69a1d24bcaab57
parent 82805 99860d7fd6ac933e93225e4a1cf898773e7d4b43
child 82807 a02f7739732095a7009fb35875693e40ab41c306
push id519
push userakeybl@mozilla.com
push dateWed, 01 Feb 2012 00:38:35 +0000
treeherdermozilla-beta@788ea1ef610b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjmaher
bugs670831
milestone11.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 670831 - Enable some mochitest sanity tests for uncaught exception handling. r=jmaher
testing/mochitest/chrome/Makefile.in
testing/mochitest/chrome/test_sanityException.xul
testing/mochitest/chrome/test_sanityException2.xul
testing/mochitest/tests/browser/Makefile.in
testing/mochitest/tests/browser/browser_sanityException.js
testing/mochitest/tests/browser/browser_sanityException2.js
--- a/testing/mochitest/chrome/Makefile.in
+++ b/testing/mochitest/chrome/Makefile.in
@@ -42,15 +42,14 @@ VPATH		= @srcdir@
 relativesrcdir  = testing/mochitest/chrome
 
 include $(DEPTH)/config/autoconf.mk
 include $(topsrcdir)/config/rules.mk
 
 _STATIC_FILES = test_sample.xul \
 		test_sanityChromeUtils.xul \
 		test_sanityPluginUtils.html \
-# Disabled until bug 652494 is resolved.
-#		test_sanityException.xul \
-#		test_sanityException2.xul \
+		test_sanityException.xul \
+		test_sanityException2.xul \
 		$(NULL)
 
 libs:: $(_STATIC_FILES)
 	$(INSTALL) $(foreach f,$^,"$f") $(DEPTH)/_tests/$(relativesrcdir)
--- a/testing/mochitest/chrome/test_sanityException.xul
+++ b/testing/mochitest/chrome/test_sanityException.xul
@@ -10,14 +10,14 @@ https://bugzilla.mozilla.org/show_bug.cg
   <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"/>
 
 <body xmlns="http://www.w3.org/1999/xhtml">
 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=670817">Mozilla Bug 670817</a>
 <script type="application/javascript"><![CDATA[
 
 SimpleTest.expectUncaughtException();
 ok(true, "a call to ok");
-throw "uncaught exception";
+throw "this is a deliberately thrown exception";
 
 ]]></script> 
 </body>
 
 </window>
--- a/testing/mochitest/chrome/test_sanityException2.xul
+++ b/testing/mochitest/chrome/test_sanityException2.xul
@@ -12,17 +12,17 @@ https://bugzilla.mozilla.org/show_bug.cg
 <body xmlns="http://www.w3.org/1999/xhtml">
 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=670817">Mozilla Bug 670817</a>
 <script type="application/javascript"><![CDATA[
 
 SimpleTest.waitForExplicitFinish();
 ok(true, "a call to ok");
 SimpleTest.executeSoon(function() {
   SimpleTest.expectUncaughtException();
-  throw "an uncaught exception";
+  throw "this is a deliberately thrown exception";
 });
 SimpleTest.executeSoon(function() {
   SimpleTest.finish();
 });
 
 ]]></script> 
 </body>
 
--- a/testing/mochitest/tests/browser/Makefile.in
+++ b/testing/mochitest/tests/browser/Makefile.in
@@ -47,19 +47,18 @@ include $(topsrcdir)/config/rules.mk
 _BROWSER_TEST_FILES = \
 	                  head.js \
 	                  browser_head.js \
 	                  browser_pass.js \
 	                  browser_async.js \
 	                  browser_privileges.js \
 	                  browser_popupNode.js \
 	                  browser_popupNode_check.js \
-# Disabled until bug 652494 is resolved.
-#			  browser_sanityException.js \
-#			  browser_sanityException2.js \
+			  browser_sanityException.js \
+			  browser_sanityException2.js \
 # Disabled, these are only good for testing the harness' failure reporting
 #	                  browser_zz_fail_openwindow.js \
 #	                  browser_fail.js \
 #	                  browser_fail_async_throw.js \
 #	                  browser_fail_fp.js \
 #	                  browser_fail_pf.js \
 #	                  browser_fail_throw.js \
 #	                  browser_fail_timeout.js \
--- a/testing/mochitest/tests/browser/browser_sanityException.js
+++ b/testing/mochitest/tests/browser/browser_sanityException.js
@@ -1,5 +1,5 @@
 function test() {
   ok(true, "ok called");
   expectUncaughtException();
-  throw "uncaught exception";
+  throw "this is a deliberately thrown exception";
 }
--- a/testing/mochitest/tests/browser/browser_sanityException2.js
+++ b/testing/mochitest/tests/browser/browser_sanityException2.js
@@ -1,11 +1,11 @@
 function test() {
   waitForExplicitFinish();
   ok(true, "ok called");
   executeSoon(function() {
     expectUncaughtException();
-    throw "uncaught exception";
+    throw "this is a deliberately thrown exception";
   });
   executeSoon(function() {
     finish();
   });
 }