Index: testing/android/reporter/java/src/org/chromium/test/reporter/TestStatusReceiver.java |
diff --git a/testing/android/reporter/java/src/org/chromium/test/reporter/TestStatusReceiver.java b/testing/android/reporter/java/src/org/chromium/test/reporter/TestStatusReceiver.java |
index f0a0d7e4a86a17090854e7943e81a847cb1e63bb..e18efa8afc04815c917ae010a9290569424d6e1e 100644 |
--- a/testing/android/reporter/java/src/org/chromium/test/reporter/TestStatusReceiver.java |
+++ b/testing/android/reporter/java/src/org/chromium/test/reporter/TestStatusReceiver.java |
@@ -37,6 +37,7 @@ public class TestStatusReceiver extends BroadcastReceiver { |
filter.addAction(TestStatusReporter.ACTION_TEST_STARTED); |
filter.addAction(TestStatusReporter.ACTION_TEST_RUN_STARTED); |
filter.addAction(TestStatusReporter.ACTION_TEST_RUN_FINISHED); |
+ filter.addAction(TestStatusReporter.ACTION_UNCAUGHT_EXCEPTION); |
try { |
filter.addDataType(TestStatusReporter.DATA_TYPE_HEARTBEAT); |
filter.addDataType(TestStatusReporter.DATA_TYPE_RESULT); |
@@ -70,6 +71,7 @@ public class TestStatusReceiver extends BroadcastReceiver { |
public interface TestRunCallback { |
void testRunStarted(int pid); |
void testRunFinished(int pid); |
+ void uncaughtException(int pid, String stackTrace); |
} |
/** Register a callback for when a test has failed. */ |
@@ -145,6 +147,11 @@ public class TestStatusReceiver extends BroadcastReceiver { |
c.testRunFinished(pid); |
} |
break; |
+ case TestStatusReporter.ACTION_UNCAUGHT_EXCEPTION: |
+ for (TestRunCallback c: mTestRunCallbacks) { |
+ c.uncaughtException(pid, stackTrace); |
+ } |
+ break; |
default: |
Log.e(TAG, "Unrecognized intent received: %s", intent.toString()); |
break; |