Don’t give a scary error about not being able to run on Android if there’s no Android device connected.
This commit is contained in:
@@ -230,13 +230,15 @@ class AndroidDevice extends _Device {
|
||||
_adbPath = _getAdbPath();
|
||||
_hasAdb = _checkForAdb();
|
||||
|
||||
// Checking for lollipop only needs to be done if we are starting an
|
||||
// app, but it has an important side effect, which is to discard any
|
||||
// progress messages if the adb server is restarted.
|
||||
_hasValidAndroid = _checkForLollipopOrLater();
|
||||
if (isConnected()) {
|
||||
// Checking for lollipop only needs to be done if we are starting an
|
||||
// app, but it has an important side effect, which is to discard any
|
||||
// progress messages if the adb server is restarted.
|
||||
_hasValidAndroid = _checkForLollipopOrLater();
|
||||
|
||||
if (!_hasAdb || !_hasValidAndroid) {
|
||||
_logging.severe('Unable to run on Android.');
|
||||
if (!_hasAdb || !_hasValidAndroid) {
|
||||
_logging.severe('Unable to run on Android.');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user