From e027a46d71943682e1137712a782a7fae478935c Mon Sep 17 00:00:00 2001 From: Hugh Willson Date: Tue, 22 Aug 2017 15:57:43 -0400 Subject: [PATCH 1/2] Add missing CLI help for test/test-packages --driver-package (#9035) --- tools/cli/help.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tools/cli/help.txt b/tools/cli/help.txt index d397e731c7b..88dd7c735e2 100644 --- a/tools/cli/help.txt +++ b/tools/cli/help.txt @@ -584,6 +584,10 @@ Options: test app rebuild. --extra-packages Run with additional packages (comma separated, for example: --extra-packages "package-name1, package-name2@1.2.3") + --driver-package Name of the optional test driver package to use to run + tests and display results. For example: + --driver-package practicalmeteor:mocha + >>> test Test the application Usage: meteor test --driver-package [options] @@ -638,6 +642,9 @@ Options: --verbose Print all output from builds logs. --extra-packages Run with additional packages (comma separated, for example: --extra-packages "package-name1, package-name2@1.2.3") + --driver-package Name of the optional test driver package to use to run + tests and display results. For example: + --driver-package practicalmeteor:mocha >>> self-test Run tests of the 'meteor' tool. From cd5405437c3050fa05648723da7a05b2baf02699 Mon Sep 17 00:00:00 2001 From: Hugh Willson Date: Tue, 22 Aug 2017 20:52:30 -0400 Subject: [PATCH 2/2] 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 1530170097a..0251f37d4fb 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 5e4b272e0c1..fbd3ec10e1d 100644 --- a/packages/test-in-browser/driver.html +++ b/packages/test-in-browser/driver.html @@ -1,6 +1,7 @@ + +