diff --git a/lib/src/util.dart b/lib/src/util.dart index 506d89c3..592a8508 100644 --- a/lib/src/util.dart +++ b/lib/src/util.dart @@ -44,7 +44,7 @@ Future retry(Future Function() f, Duration interval, /// Potentially useful as a means to extract it from log statements. Uri? extractVMServiceUri(String str) { final listeningMessageRegExp = RegExp( - r'(?:Observatory|Dart VM Service) listening on ((http|//)[a-zA-Z0-9:/=_\-\.\[\]]+)', + r'(?:Observatory|The Dart VM Service is) listening on ((http|//)[a-zA-Z0-9:/=_\-\.\[\]]+)', ); final match = listeningMessageRegExp.firstMatch(str); if (match != null) { diff --git a/test/util_test.dart b/test/util_test.dart index 403a022a..a0077c79 100644 --- a/test/util_test.dart +++ b/test/util_test.dart @@ -130,7 +130,8 @@ void main() { }); test('handles new Dart VM service message format', () { - const msg = 'Dart VM Service listening on http://foo.bar:9999/cG90YXRv/'; + const msg = + 'The Dart VM Service is listening on http://foo.bar:9999/cG90YXRv/'; expect( extractVMServiceUri(msg), Uri.parse('http://foo.bar:9999/cG90YXRv/')); });