Home
last modified time | relevance | path

Searched refs:thrown (Results 1 – 8 of 8) sorted by relevance

/cts/tools/vm-tests-tf/src/dot/junit/
DDxTestCase.java23 private static void checkError(Class<?> expectedErrorClass, Throwable thrown, in checkError() argument
25 if (expectedErrorClass != null && thrown == null) { in checkError()
27 } else if (expectedErrorClass == null && thrown != null) { in checkError()
28 fail("Unexpected error " + thrown); in checkError()
29 } else if (expectedErrorClass != null && thrown != null) { in checkError()
31 if (!(thrown instanceof java.lang.reflect.InvocationTargetException)) { in checkError()
32 fail("Expected invocation target exception, but got " + thrown); in checkError()
34 thrown = thrown.getCause(); in checkError()
36 if (!expectedErrorClass.equals(thrown.getClass())) { in checkError()
38 thrown.getClass()); in checkError()
DDxAbstractMain.java25 private static void checkError(Class<?> expectedErrorClass, Throwable thrown, in checkError() argument
27 if (expectedErrorClass != null && thrown == null) { in checkError()
29 } else if (expectedErrorClass == null && thrown != null) { in checkError()
30 fail("Unexpected error " + thrown, thrown); in checkError()
31 } else if (expectedErrorClass != null && thrown != null) { in checkError()
33 if (!(thrown instanceof java.lang.reflect.InvocationTargetException)) { in checkError()
34 fail("Expected invocation target exception, but got " + thrown, thrown); in checkError()
36 thrown = thrown.getCause(); in checkError()
38 if (!expectedErrorClass.equals(thrown.getClass())) { in checkError()
40 thrown.getClass(), thrown); in checkError()
/cts/hostsidetests/appsecurity/src/android/appsecurity/cts/
DMatcherUtils.java100 Throwable thrown;
103 thrown = null;
105 thrown = t;
107 assertOrRethrow(thrown, exceptionCond);
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/
DMatcherUtils.java118 Throwable thrown;
121 thrown = null;
123 thrown = t;
125 assertOrRethrow(thrown, exceptionCond);
/cts/tests/tests/media/src/android/media/cts/
DAudioSystemUsageTest.java107 UnsupportedOperationException thrown = expectThrows(UnsupportedOperationException.class, in getOutputForAttr_returnsError() local
109 assertThat(thrown).hasMessageThat().contains("Cannot create AudioTrack"); in getOutputForAttr_returnsError()
122 UnsupportedOperationException thrown = expectThrows(UnsupportedOperationException.class, in getInputForAttr_returnsError() local
124 assertThat(thrown).hasMessageThat().contains("Cannot create AudioRecord"); in getInputForAttr_returnsError()
/cts/tests/tests/print/printTestUtilLib/src/android/print/test/
DUtils.java82 final Throwable[] thrown = new Throwable[1]; in runOnMainThread() local
90 thrown[0] = t; in runOnMainThread()
100 if (thrown[0] != null) { in runOnMainThread()
101 throw thrown[0]; in runOnMainThread()
/cts/tests/tests/carrierapi/src/android/carrierapi/cts/
DBugreportManagerTest.java447 } catch (Throwable thrown) { in assertExceptionThrownForMode()
448 if (!exceptionType.isInstance(thrown)) { in assertExceptionThrownForMode()
449 throw thrown; in assertExceptionThrownForMode()
/cts/tools/cts-api-coverage/proto/
Dcts_report.proto317 // Captures an exception thrown during the test.