diff --git a/packages/flutter_tools/lib/src/runner/target_devices.dart b/packages/flutter_tools/lib/src/runner/target_devices.dart index a639096bd9..92e802e89a 100644 --- a/packages/flutter_tools/lib/src/runner/target_devices.dart +++ b/packages/flutter_tools/lib/src/runner/target_devices.dart @@ -29,7 +29,9 @@ String _foundSpecifiedDevicesMessage(int count, String deviceId) => String _noMatchingDeviceMessage(String deviceId) => 'No supported devices found with name or id ' "matching '$deviceId'."; String flutterSpecifiedDeviceDevModeDisabled(String deviceName) => 'To use ' - "'$deviceName' for development, enable Developer Mode in Settings → Privacy & Security."; + "'$deviceName' for development, enable Developer Mode in Settings → Privacy & Security on the device. " + 'If this does not work, open Xcode, reconnect the device, and look for a ' + 'popup on the device asking you to trust this computer.'; String flutterSpecifiedDeviceUnpaired(String deviceName) => "'$deviceName' is not paired. " 'Open Xcode and trust this computer when prompted.'; diff --git a/packages/flutter_tools/test/general.shard/runner/target_devices_test.dart b/packages/flutter_tools/test/general.shard/runner/target_devices_test.dart index 5e5add9670..184d79a3db 100644 --- a/packages/flutter_tools/test/general.shard/runner/target_devices_test.dart +++ b/packages/flutter_tools/test/general.shard/runner/target_devices_test.dart @@ -1267,8 +1267,8 @@ target-device (mobile) • xxx • ios • iOS 16 (unsupported) final List? devices = await targetDevices.findAllTargetDevices(); - expect(logger.statusText, equals(''' -To use 'target-device' for development, enable Developer Mode in Settings → Privacy & Security. + expect(logger.statusText, equals(r''' +To use 'target-device' for development, enable Developer Mode in Settings → Privacy & Security on the device. If this does not work, open Xcode, reconnect the device, and look for a popup on the device asking you to trust this computer. ''')); expect(devices, isNull); }); @@ -1279,7 +1279,7 @@ To use 'target-device' for development, enable Developer Mode in Settings → Pr final List? devices = await targetDevices.findAllTargetDevices(); expect(logger.statusText, equals(''' -To use 'target-device-1' for development, enable Developer Mode in Settings → Privacy & Security. +To use 'target-device-1' for development, enable Developer Mode in Settings → Privacy & Security on the device. If this does not work, open Xcode, reconnect the device, and look for a popup on the device asking you to trust this computer. Checking for wireless devices... ''')); expect(devices, isNotNull); @@ -1292,8 +1292,8 @@ Checking for wireless devices... final List? devices = await targetDevices.findAllTargetDevices(); expect(logger.statusText, equals(''' -To use 'target-device-1' for development, enable Developer Mode in Settings → Privacy & Security. -To use 'target-device-2' for development, enable Developer Mode in Settings → Privacy & Security. +To use 'target-device-1' for development, enable Developer Mode in Settings → Privacy & Security on the device. If this does not work, open Xcode, reconnect the device, and look for a popup on the device asking you to trust this computer. +To use 'target-device-2' for development, enable Developer Mode in Settings → Privacy & Security on the device. If this does not work, open Xcode, reconnect the device, and look for a popup on the device asking you to trust this computer. No devices found yet. Checking for wireless devices... No supported devices found with name or id matching 'target-device'.