Skip to content

Commit

Permalink
Update setup guide URL for Espresso Device setup
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 670696336
  • Loading branch information
Paige McAuliffe authored and copybara-androidxtest committed Sep 3, 2024
1 parent 453f494 commit 045dda0
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
1 change: 1 addition & 0 deletions espresso/device/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

* Add support for setting screen orientation with multiple resumed activities
* Fix concurrent modification issue when setting screen orientation and fold modes
* Adjust reference docs to state set up guide is now located at https://developer.android.com/studio/test/espresso-api#set_up_your_project_for_the_espresso_device_api

**New Features**

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ constructor(
private val TAG = EmulatorController::class.java.simpleName
private const val DEGREES_TO_ROTATE_LANDSCAPE_TO_PORTRAIT = -90F
private const val DEGREES_TO_ROTATE_PORTRAIT_TO_LANDSCAPE = 90F
private const val additionalSetUpInstructions =
" See https://developer.android.com/studio/test/espresso-api#set_up_your_project_for_the_espresso_device_api for set up instructions."
}

override fun setDeviceMode(deviceMode: Int) {
Expand Down Expand Up @@ -82,8 +84,8 @@ constructor(
throw DeviceControllerOperationException(
"Failed to set device mode. Please make sure the connected Emulator is foldable, the Android Emulator version" +
" is updated to 33.1.11+, and the controller gRPC service is enabled on the emulator" +
" See https://developer.android.com/studio/preview/features#set_up_your_project_for_the_espresso_device_api for set up instructions.",
e
additionalSetUpInstructions,
e,
)
}
}
Expand Down Expand Up @@ -131,8 +133,8 @@ constructor(
throw DeviceControllerOperationException(
"Failed to set screen orientation. Please make sure the Android Emulator version" +
" is updated to 33.1.11+ and the controller gRPC service is enabled on the emulator." +
" See https://developer.android.com/studio/preview/features#set_up_your_project_for_the_espresso_device_api for set up instructions.",
e
additionalSetUpInstructions,
e,
)
}
}
Expand All @@ -150,8 +152,8 @@ constructor(
) {
throw DeviceControllerOperationException(
"The current process does not have the INTERNET permission. Ensure the app-under-test has '<uses-permission " +
"android:name=\"android.permission.INTERNET\"/>' in its AndroidManifest.xml. See " +
"See https://developer.android.com/studio/preview/features#set_up_your_project_for_the_espresso_device_api for set up instructions."
"android:name=\"android.permission.INTERNET\"/>' in its AndroidManifest.xml." +
additionalSetUpInstructions
)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ internal class DeviceControllerModule {
throw DeviceControllerOperationException(
"Unable to connect to Emulator gRPC port. Please make sure the Android Emulator version" +
" is updated to 33.1.11+ and the controller gRPC service is enabled on the emulator." +
" See https://developer.android.com/studio/preview/features#set_up_your_project_for_the_espresso_device_api for set up instructions."
" See https://developer.android.com/studio/test/espresso-api#set_up_your_project_for_the_espresso_device_api for set up instructions."
)
}
return gRpcPort.toInt()
Expand Down

0 comments on commit 045dda0

Please sign in to comment.