Skip to content

Commit 3c943d7

Browse files
committed
fix an issue parsing 'adb devices' output
1 parent c49f07e commit 3c943d7

3 files changed

Lines changed: 14 additions & 5 deletions

File tree

packages/flutter_tools/lib/src/device.dart

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -545,6 +545,12 @@ class AndroidDevice extends Device {
545545

546546
// Skip first line, which is always 'List of devices attached'.
547547
for (String line in output.skip(1)) {
548+
// Skip lines like:
549+
// * daemon not running. starting it now on port 5037 *
550+
// * daemon started successfully *
551+
if (line.startsWith('* daemon '))
552+
continue;
553+
548554
if (deviceRegex1.hasMatch(line)) {
549555
Match match = deviceRegex1.firstMatch(line);
550556
String deviceID = match[1];
@@ -563,9 +569,10 @@ class AndroidDevice extends Device {
563569
String deviceID = match[1];
564570
devices.add(new AndroidDevice(id: deviceID));
565571
} else {
566-
_logging.warning('Unexpected failure parsing device information '
567-
'from adb output:\n$line\n'
568-
'Please report a bug at http://flutter.io/');
572+
_logging.warning(
573+
'Unexpected failure parsing device information from adb output:\n'
574+
'$line\n'
575+
'Please report a bug at http://flutter.io/');
569576
}
570577
}
571578
return devices;

travis/setup.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ pub global activate tuneup
88
(cd packages/flutter_tools; pub get)
99
(cd packages/flx; pub get)
1010
(cd packages/newton; pub get)
11+
(cd packages/playfair; pub get)
1112
(cd packages/unit; pub get)
1213
(cd packages/updater; pub get)
1314

travis/test.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,11 @@
22
set -ex
33

44
(cd packages/cassowary; pub global run tuneup check; pub run test -j1)
5-
(cd packages/flutter_sprites; pub global run tuneup check)
5+
(cd packages/flutter_sprites; pub global run tuneup check) # No tests to run.
66
(cd packages/flutter_tools; pub global run tuneup check; pub run test -j1)
77
(cd packages/flx; pub global run tuneup check; pub run test -j1)
88
(cd packages/newton; pub global run tuneup check; pub run test -j1)
9-
(cd packages/updater; pub global run tuneup check)
9+
(cd packages/playfair; pub global run tuneup check) # No tests to run.
10+
(cd packages/updater; pub global run tuneup check) # No tests to run.
1011

1112
./bin/flutter test --engine-src-path bin/cache/travis

0 commit comments

Comments
 (0)