From cd5405437c3050fa05648723da7a05b2baf02699 Mon Sep 17 00:00:00 2001 From: Hugh Willson Date: Tue, 22 Aug 2017 20:52:30 -0400 Subject: [PATCH] Visually notify of uncaught exceptions breaking client tests (#9034) * Visually notify of uncaught exceptions breaking client tests These changes add a global `window.onerror` event handler to the `test-in-browser` package, to catch any previously uncaught exceptions. When uncaught exceptions are found, an alert box is displayed above the test results table. This should help notify developers of hidden uncaught exceptions that could be preventing client tests from running. Fixes #4979. * Bump the test-in-browser package version --- packages/test-in-browser/driver.css | 6 ++++- packages/test-in-browser/driver.html | 39 +++++++++++++++++++++++----- packages/test-in-browser/driver.js | 13 ++++++++++ packages/test-in-browser/package.js | 3 ++- 4 files changed, 52 insertions(+), 9 deletions(-) diff --git a/packages/test-in-browser/driver.css b/packages/test-in-browser/driver.css index 1530170097..0251f37d4f 100644 --- a/packages/test-in-browser/driver.css +++ b/packages/test-in-browser/driver.css @@ -151,4 +151,8 @@ body { #current-client-test { color: #ccc; margin-right: 15px; -} \ No newline at end of file +} + +.failedTests { + color: #900; /* red */ +} diff --git a/packages/test-in-browser/driver.html b/packages/test-in-browser/driver.html index 5e4b272e0c..fbd3ec10e1 100644 --- a/packages/test-in-browser/driver.html +++ b/packages/test-in-browser/driver.html @@ -1,6 +1,7 @@ + +