/cts/common/device-side/bedstead/remoteframeworkclasses/src/types/main/java/com/android/bedstead/remoteframeworkclasses/ |
D | SimpleAccountManagerFuture.java | 63 Throwable exception = mException.get(); in getResult() local 64 if (exception == null) { in getResult() 66 } else if (exception instanceof OperationCanceledException) { in getResult() 67 throw (OperationCanceledException) exception; in getResult() 68 } else if (exception instanceof IOException) { in getResult() 69 throw (IOException) exception; in getResult() 70 } else if (exception instanceof AuthenticatorException) { in getResult() 71 throw (AuthenticatorException) exception; in getResult() 73 throw new RuntimeException("Unexpected exception type", exception); in getResult() 92 Throwable exception = mException.get(); in getResult() local [all …]
|
/cts/tests/tests/car/src/android/car/cts/ |
D | ExceptionsTest.java | 38 CarNotConnectedException exception = new CarNotConnectedException(); in testCarNotConnectedException() local 39 assertThat(exception.getMessage()).isNull(); in testCarNotConnectedException() 40 assertThat(exception.getCause()).isNull(); in testCarNotConnectedException() 42 exception = new CarNotConnectedException(MESSAGE); in testCarNotConnectedException() 43 assertThat(exception.getMessage()).isEqualTo(MESSAGE); in testCarNotConnectedException() 44 assertThat(exception.getCause()).isNull(); in testCarNotConnectedException() 46 exception = new CarNotConnectedException(MESSAGE, CAUSE); in testCarNotConnectedException() 47 assertThat(exception.getMessage()).isEqualTo(MESSAGE); in testCarNotConnectedException() 48 assertThat(exception.getCause()).isSameInstanceAs(CAUSE); in testCarNotConnectedException() 50 exception = new CarNotConnectedException(CAUSE); in testCarNotConnectedException() [all …]
|
D | PlatformVersionMismatchExceptionTest.java | 39 PlatformVersionMismatchException exception = new PlatformVersionMismatchException( in testExpectedVersionAndMessage() local 43 PlatformVersion expectedApiVersion = exception.getMinimumPlatformApiVersion(); in testExpectedVersionAndMessage() 48 String message = exception.getMessage(); in testExpectedVersionAndMessage() 60 PlatformVersionMismatchException exception = new PlatformVersionMismatchException( in testExceptionParceable() local 66 exception.writeToParcel(parcel, 0); in testExceptionParceable() 75 .isEqualTo(exception.getMinimumPlatformApiVersion()); in testExceptionParceable()
|
/cts/tests/tests/binder_ndk/libbinder_ndk_test/ |
D | test_status.cpp | 75 binder_exception_t exception, in checkIsErrorException() argument 79 EXPECT_EQ(exception, AStatus_getExceptionCode(status)); in checkIsErrorException() 82 EXPECT_EQ(exception == EX_TRANSACTION_FAILED ? STATUS_FAILED_TRANSACTION in checkIsErrorException() 123 for (binder_exception_t exception : kErrorExceptions) { in TEST() local 124 AStatus* status = AStatus_fromExceptionCode(exception); in TEST() 125 checkIsErrorException(status, exception, "" /*message*/); in TEST() 132 for (binder_exception_t exception : kErrorExceptions) { in TEST() local 134 AStatus_fromExceptionCodeWithMessage(exception, kMessage.c_str()); in TEST() 135 checkIsErrorException(status, exception, kMessage); in TEST() 167 for (binder_exception_t exception : kUnknownExceptions) { in TEST() local [all …]
|
/cts/tests/tests/bluetooth/src/android/bluetooth/cts/ |
D | BluetoothSocketExceptionTest.java | 32 BluetoothSocketException exception = in test_getErrorCode_returnsCorrectErrorCode() local 35 assertEquals(exception.getErrorCode(), BluetoothSocketException.SOCKET_CONNECTION_FAILURE); in test_getErrorCode_returnsCorrectErrorCode() 41 BluetoothSocketException exception = in test_getMessage_returnsCustomErrorMsg() local 44 assertEquals(exception.getMessage(), customErrMsg); in test_getMessage_returnsCustomErrorMsg() 49 BluetoothSocketException exception = in test_getMessage_returnsErrorMsgWhenOnlyCodeIsProvided() local 52 assertNotNull(exception.getMessage()); in test_getMessage_returnsErrorMsgWhenOnlyCodeIsProvided()
|
D | BluetoothServiceManagerTest.java | 60 } catch (ServiceNotFoundException exception) { in test_ServiceRegisterer() 75 } catch (ServiceNotFoundException exception) { in test_ServiceNotFoundException() 76 assertEquals(baseExceptionDescription + exceptionDescription, exception.getMessage()); in test_ServiceNotFoundException()
|
/cts/common/device-side/util-axt/tests/src/com/android/compatibility/common/util/ |
D | RetryRuleTest.java | 52 RetryableStatement(int numberFailures, T exception) { in RetryableStatement() argument 53 this(numberFailures, exception, null); in RetryableStatement() 56 RetryableStatement(int numberFailures, T exception, @Nullable Runnable cleaner) { in RetryableStatement() argument 58 mException = exception; in RetryableStatement() 138 final RetryableException exception = new RetryableException("Y U NO?"); in testNeverCleanWhenDisabledAndStatementThrowsRetryableException() local 141 doThrow(exception).when(mMockStatement).evaluate(); in testNeverCleanWhenDisabledAndStatementThrowsRetryableException() 146 assertThat(actualException).isSameInstanceAs(exception); in testNeverCleanWhenDisabledAndStatementThrowsRetryableException() 154 final RetryableException exception = new RetryableException(timeout, "Y U NO?"); in testPassOnRetryableExceptionWithTimeout() local 157 rule.apply(new RetryableStatement<RetryableException>(1, exception), mDescription) in testPassOnRetryableExceptionWithTimeout() 186 final RetryableException exception = new RetryableException("Y U NO?"); in testFailWhenDisabledAndStatementThrowsRetryableException() local [all …]
|
/cts/hostsidetests/appsecurity/test-apps/EphemeralTestApp/NormalApp/src/com/android/cts/normalapp/ |
D | ExposedService.java | 33 String exception = null; in onBind() local 37 exception = t.getClass().getName(); in onBind() 44 .setException(exception) in onBind() 54 String exception = null; in onStartCommand() local 58 exception = t.getClass().getName(); in onStartCommand() 65 .setException(exception) in onStartCommand()
|
D | NormalService.java | 37 String exception = null; in onStartCommand() local 41 exception = t.getClass().getName(); in onStartCommand() 48 .setException(exception) in onStartCommand()
|
D | ExposedActivity.java | 41 String exception = null; in onCreate() local 45 exception = t.getClass().getName(); in onCreate() 52 .setException(exception) in onCreate()
|
D | NormalWebActivity.java | 43 String exception = null; in onCreate() local 47 exception = t.getClass().getName(); in onCreate() 54 .setException(exception) in onCreate()
|
D | NormalActivity.java | 50 String exception = null; in onCreate() local 54 exception = t.getClass().getName(); in onCreate() 61 .setException(exception) in onCreate()
|
/cts/common/device-side/bedstead/nene/src/main/java/com/android/bedstead/nene/utils/ |
D | Assert.kt | 29 exception: Class<E>? = null, in assertThrows() 31 val exceptionType = exception?.toString() ?: "an exception" in assertThrows() 36 if (exception?.isInstance(e) == true) { in assertThrows() 50 fun <E : Throwable?> assertThrows(exception: Class<E>? = null, executable: Runnable): E = in assertThrows() 51 assertThrows(null, exception) { executable.run() } in assertThrows()
|
/cts/tests/tests/content/src/android/content/pm/cts/ |
D | PackageManager_NameNotFoundExceptionTest.java | 29 PackageManager.NameNotFoundException exception = new PackageManager.NameNotFoundException(); in testNameNotFoundException() local 31 throw exception; in testNameNotFoundException() 37 exception = new PackageManager.NameNotFoundException(message); in testNameNotFoundException() 39 throw exception; in testNameNotFoundException()
|
/cts/hostsidetests/appsecurity/test-apps/AppDataIsolationTestApp/common/src/com/android/cts/appdataisolation/common/ |
D | FileUtils.java | 57 Exception exception = expectThrows(FileNotFoundException.class, () -> { in assertDirIsNotAccessible() local 60 assertThat(exception.getMessage()).contains(JAVA_FILE_PERMISSION_DENIED_MSG); in assertDirIsNotAccessible() 61 assertThat(exception.getMessage()).doesNotContain(JAVA_FILE_NOT_FOUND_MSG); in assertDirIsNotAccessible() 70 Exception exception = expectThrows(FileNotFoundException.class, () -> { in assertDirDoesNotExist() local 73 assertThat(exception.getMessage()).contains(JAVA_FILE_NOT_FOUND_MSG); in assertDirDoesNotExist() 74 assertThat(exception.getMessage()).doesNotContain(JAVA_FILE_PERMISSION_DENIED_MSG); in assertDirDoesNotExist() 116 Exception exception = expectThrows(FileNotFoundException.class, () -> { in assertFileDoesNotExist() local 119 assertThat(exception.getMessage()).contains(JAVA_FILE_NOT_FOUND_MSG); in assertFileDoesNotExist() 120 assertThat(exception.getMessage()).doesNotContain(JAVA_FILE_PERMISSION_DENIED_MSG); in assertFileDoesNotExist()
|
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/ |
D | BroadcastRpcBase.java | 89 final String exception = responseBundle.get().getString(EXTRA_EXCEPTION); in invoke() local 90 if (exception != null) { in invoke() 92 + "\nException: " + exception); in invoke() 116 Throwable exception = null; in onReceive() local 124 exception = e; in onReceive() 133 if (exception != null) { in onReceive() 135 exception.toString() + "\n" + Log.getStackTraceString(exception)); in onReceive()
|
D | ShellUtils.java | 47 AtomicReference<Exception> exception = new AtomicReference<>(null); in runShellCommandWithTimeout() local 56 exception.set(e); in runShellCommandWithTimeout() 71 if (exception.get() != null) { in runShellCommandWithTimeout() 72 throw new AndroidRuntimeException(exception.get()); in runShellCommandWithTimeout()
|
/cts/tests/tests/appop/ndk-jni/android/app/appops/cts/ |
D | NDKAppOpsLoggingTest.cpp | 24 jclass exception = env->FindClass("java/lang/RuntimeException"); in Java_android_app_appops_cts_AppOpsLoggingTestKt_nativeStartStopAudioRecord() local 38 env->ThrowNew(exception, "Failed to create audio stream builder"); in Java_android_app_appops_cts_AppOpsLoggingTestKt_nativeStartStopAudioRecord() 63 env->ThrowNew(exception, "Failed to create audio stream"); in Java_android_app_appops_cts_AppOpsLoggingTestKt_nativeStartStopAudioRecord() 69 env->ThrowNew(exception, "Failed to start audio stream"); in Java_android_app_appops_cts_AppOpsLoggingTestKt_nativeStartStopAudioRecord()
|
/cts/tests/tests/security/src/android/security/cts/BUG_283103220/ |
D | PipActivity.java | 52 } catch (Exception exception) { in onResume() 54 sendBroadcastResult(null, exception); in onResume() 88 private void sendBroadcastResult(String vulnerableMethods, Exception exception) { in sendBroadcastResult() argument 91 .putExtra(BUG_283103220.BUG_283103220_EXCEPTION, exception) in sendBroadcastResult()
|
/cts/tests/tests/security/src/android/security/cts/CVE_2024_0024/ |
D | PocActivity.java | 31 String exception = null; in onResume() local 56 exception = e.getMessage(); in onResume() 62 .putExtra(getString(R.string.CVE_2024_0024_exception), exception) in onResume()
|
/cts/tests/tests/os/src/android/os/cts/ |
D | AsyncTaskTest.java | 77 if (mMyAsyncTask.exception != null) { in doTestAsyncTask() 78 throw mMyAsyncTask.exception; in doTestAsyncTask() 114 assertNotNull(mMyAsyncTask.exception); in testCancelWithInterrupt() 115 assertTrue(mMyAsyncTask.exception instanceof InterruptedException); in testCancelWithInterrupt() 127 assertNull(mMyAsyncTask.exception); in testCancel() 136 assertNull(mMyAsyncTask.exception); in testCancelTooLate() 232 public Exception exception; field in AsyncTaskTest.MyAsyncTask 245 exception = e; in doInBackground()
|
/cts/tests/tests/security/src/android/security/cts/CVE_2024_23713/ |
D | PocNotificationListenerService.java | 31 String exception = null; in onListenerConnected() local 48 exception = e.getMessage(); in onListenerConnected() 52 intent.putExtra(getString(R.string.CVE_2024_23713_exception), exception) in onListenerConnected()
|
/cts/hostsidetests/appsecurity/test-apps/EphemeralTestApp/ImplicitlyExposedApp/src/com/android/cts/implicitapp/ |
D | ImplicitActivity.java | 40 String exception = null; in onCreate() local 44 exception = t.getClass().getName(); in onCreate() 51 .setException(exception) in onCreate()
|
/cts/tests/devicepolicy/src/android/devicepolicy/cts/ |
D | UnsafeStateExceptionTest.java | 58 UnsafeStateException exception = new UnsafeStateException(VALID_OPERATION, reason); in assertExceptionWithValidReason() local 60 assertWithMessage("operation").that(exception.getOperation()).isEqualTo(VALID_OPERATION); in assertExceptionWithValidReason() 61 assertWithMessage("reasons").that(exception.getReasons()).containsExactly(reason); in assertExceptionWithValidReason()
|
/cts/tests/tests/nfc/src/android/nfc/cts/ |
D | NfcServiceManagerTest.java | 60 } catch (ServiceNotFoundException exception) { in test_ServiceRegisterer() 75 } catch (ServiceNotFoundException exception) { in test_ServiceNotFoundException() 76 assertEquals(baseExceptionDescription + exceptionDescription, exception.getMessage()); in test_ServiceNotFoundException()
|