Remove unused code from `test/` (#9918)
diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml
index 125a7ca..5f94a51 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yaml
@@ -11,7 +11,8 @@
       - master
 
 # Declare default permissions as read only.
-permissions: read-all
+permissions:
+  contents: read
 
 defaults:
   run:
@@ -74,7 +75,7 @@
           wget -qO- https://dcm.dev/pgp-key.public | sudo gpg --dearmor -o /usr/share/keyrings/dcm.gpg
           echo 'deb [signed-by=/usr/share/keyrings/dcm.gpg arch=amd64] https://dcm.dev/debian stable main' | sudo tee /etc/apt/sources.list.d/dart_stable.list
           sudo apt-get update
-          sudo apt-get install dcm=1.38.1-1 # To avoid errors add `-1` (build number) to the version
+          sudo apt-get install dcm=1.38.3-1 # To avoid errors add `-1` (build number) to the version
           sudo chmod +x /usr/bin/dcm
           echo "$(dcm --version)"
       - name: Setup Dart SDK
@@ -190,7 +191,7 @@
         run: ./tool/ci/bots.sh
 
       - name: Upload Golden Failure Artifacts
-        uses: actions/upload-artifact@v7
+        uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a
         if: failure()
         with:
           name: golden_image_failures.${{ matrix.bot }}
@@ -263,7 +264,7 @@
         run: ./tool/ci/bots.sh
 
       - name: Upload Golden Failure Artifacts
-        uses: actions/upload-artifact@v7
+        uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a
         if: failure()
         with:
           name: golden_image_failures.${{ matrix.bot }}
diff --git a/analysis_options.yaml b/analysis_options.yaml
index e5b9fd1..7438d8d 100644
--- a/analysis_options.yaml
+++ b/analysis_options.yaml
@@ -174,8 +174,8 @@
       - lib/src/screens/inspector/**_controller.dart
       - lib/src/shared/diagnostics/inspector_service.dart
       - lib/src/shared/diagnostics/diagnostics_node.dart
-
-      - test/**
+      # This fixture has unused code for testing the debugger.
+      - test/test_infra/fixtures/flutter_app/**
   rules:
 #    - arguments-ordering Too strict
 #    - avoid-banned-imports # TODO(polina-c): add configuration
diff --git a/flutter-candidate.txt b/flutter-candidate.txt
index 5900694..f094eb2 100644
--- a/flutter-candidate.txt
+++ b/flutter-candidate.txt
@@ -1 +1 @@
-ad80825c24d770a19e33f67800fc0338a3b89ec7
+0f0246377b1c9d8bc365a439c520a7de6c3f590b
diff --git a/packages/devtools_app/lib/src/screens/performance/performance_controller.dart b/packages/devtools_app/lib/src/screens/performance/performance_controller.dart
index a41441f..b9e1580 100644
--- a/packages/devtools_app/lib/src/screens/performance/performance_controller.dart
+++ b/packages/devtools_app/lib/src/screens/performance/performance_controller.dart
@@ -48,13 +48,10 @@
   @override
   final screenId = ScreenMetaData.performance.id;
 
-  // ignore: dispose-class-fields, false positive. See `applyToFeatureControllers` in the dispose() method.
   late final FlutterFramesController flutterFramesController;
 
-  // ignore: dispose-class-fields, false positive. See `applyToFeatureControllers` in the dispose() method.
   late final TimelineEventsController timelineEventsController;
 
-  // ignore: dispose-class-fields, false positive. See `applyToFeatureControllers` in the dispose() method.
   late final RebuildStatsController rebuildStatsController;
 
   // ignore: dispose-class-fields, false positive. See `applyToFeatureControllers` in the dispose() method.
diff --git a/packages/devtools_app/test/screens/cpu_profiler/cpu_profile_benchmark_test.dart b/packages/devtools_app/test/screens/cpu_profiler/cpu_profile_benchmark_test.dart
index 59ed603..b4e7d43 100644
--- a/packages/devtools_app/test/screens/cpu_profiler/cpu_profile_benchmark_test.dart
+++ b/packages/devtools_app/test/screens/cpu_profiler/cpu_profile_benchmark_test.dart
@@ -35,7 +35,7 @@
       final score = await benchmark.measure();
       expect(
         score,
-        lessThan(110000),
+        lessThan(120000),
         reason: 'Exceeded benchmark for run $i: $score',
       );
     }
diff --git a/packages/devtools_app/test/screens/inspector/inspector_integration_test.dart b/packages/devtools_app/test/screens/inspector/inspector_integration_test.dart
index 65ab143..970108a 100644
--- a/packages/devtools_app/test/screens/inspector/inspector_integration_test.dart
+++ b/packages/devtools_app/test/screens/inspector/inspector_integration_test.dart
@@ -31,14 +31,39 @@
 // reduced to under 1 second without introducing flakes.
 const inspectorChangeSettleTime = Duration(seconds: 2);
 
+void _copyDirectorySync(Directory source, Directory destination) {
+  if (!destination.existsSync()) {
+    destination.createSync(recursive: true);
+  }
+  for (final entity in source.listSync()) {
+    final newPath = p.join(destination.path, p.basename(entity.path));
+    if (entity is Directory) {
+      _copyDirectorySync(entity, Directory(newPath));
+    } else if (entity is File) {
+      entity.copySync(newPath);
+    }
+  }
+}
+
 void main() {
   // We need to use real async in this test so we need to use this binding.
   initializeLiveTestWidgetsFlutterBindingWithAssets();
   const windowSize = Size(2600.0, 1200.0);
 
+  // We copy the fixture app to a temporary directory because the
+  // auto-refresh tests modify lib/main.dart in-place. If this used the shared
+  // 'inspector_app' fixture, it could cause flaky test failures in other tests
+  // (like inspector_service_test.dart) that run in parallel.
+  final tempAppDir =
+      'test/test_infra/fixtures/inspector_app_temp_${DateTime.now().millisecondsSinceEpoch}';
+  _copyDirectorySync(
+    Directory('test/test_infra/fixtures/inspector_app'),
+    Directory(tempAppDir),
+  );
+
   final env = FlutterTestEnvironment(
     const FlutterRunConfiguration(withDebugger: true),
-    testAppDirectory: 'test/test_infra/fixtures/inspector_app',
+    testAppDirectory: tempAppDir,
   );
 
   env.afterEverySetup = () async {
@@ -67,6 +92,10 @@
 
   tearDownAll(() {
     env.finalTeardown();
+    final dir = Directory(tempAppDir);
+    if (dir.existsSync()) {
+      dir.deleteSync(recursive: true);
+    }
   });
 
   group('screenshot tests', () {
@@ -653,17 +682,6 @@
   expect(propertyNameCenter.dy, equals(propertyValueCenter.dy));
 }
 
-bool areHorizontallyAligned(
-  Finder widgetAFinder,
-  Finder widgetBFinder, {
-  required WidgetTester tester,
-}) {
-  final widgetACenter = tester.getCenter(widgetAFinder);
-  final widgetBCenter = tester.getCenter(widgetBFinder);
-
-  return widgetACenter.dy == widgetBCenter.dy;
-}
-
 bool _treeRowsAreInOrder({
   required List<String> treeRowDescriptions,
   required int startingAtIndex,
diff --git a/packages/devtools_app/test/screens/memory/framework/memory_service_test.dart b/packages/devtools_app/test/screens/memory/framework/memory_service_test.dart
deleted file mode 100644
index 650f13a..0000000
--- a/packages/devtools_app/test/screens/memory/framework/memory_service_test.dart
+++ /dev/null
@@ -1,66 +0,0 @@
-// Copyright 2019 The Flutter Authors
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file or at https://developers.google.com/open-source/licenses/bsd.
-
-import 'package:devtools_app/src/screens/memory/framework/memory_controller.dart';
-import 'package:devtools_app/src/screens/memory/shared/primitives/memory_timeline.dart';
-import 'package:flutter_test/flutter_test.dart';
-
-import '../../../test_infra/flutter_test_driver.dart'
-    show FlutterRunConfiguration;
-import '../../../test_infra/flutter_test_environment.dart';
-
-late MemoryController memoryController;
-
-// Track number of onMemory events received.
-int memoryTrackersReceived = 0;
-
-int previousTimestamp = 0;
-
-bool firstSample = true;
-
-void main() {
-  // TODO(https://github.com/flutter/devtools/issues/2053): rewrite.
-  // ignore: dead_code
-  if (false) {
-    final env = FlutterTestEnvironment(
-      const FlutterRunConfiguration(withDebugger: true),
-    );
-
-    env.afterNewSetup = () {
-      memoryController = MemoryController();
-    };
-  }
-}
-
-void validateHeapInfo(MemoryTimeline timeline) {
-  for (final sample in timeline.data) {
-    expect(sample.timestamp, greaterThan(0));
-    expect(sample.timestamp, greaterThan(previousTimestamp));
-
-    expect(sample.used, greaterThan(0));
-    expect(sample.used, lessThan(sample.capacity));
-
-    expect(sample.external, greaterThan(0));
-    expect(sample.external, lessThan(sample.capacity));
-
-    // TODO(terry): Bug - VM's first HeapSample returns a null for the rss value.
-    //              Subsequent samples the rss values are valid integers.  This is
-    //              a VM regression https://github.com/dart-lang/sdk/issues/40766.
-    //              When fixed, remove below test rss != null and firstSample global.
-    if (firstSample) {
-      expect(sample.rss, greaterThan(0));
-      expect(sample.rss, greaterThan(sample.capacity));
-      firstSample = false;
-    }
-
-    expect(sample.capacity, greaterThan(0));
-    expect(sample.capacity, greaterThan(sample.used + sample.external));
-
-    previousTimestamp = sample.timestamp;
-  }
-
-  timeline.data.clear();
-
-  memoryTrackersReceived++;
-}
diff --git a/packages/devtools_app/test/shared/primitives/utils_test.dart b/packages/devtools_app/test/shared/primitives/utils_test.dart
index 941165d..f71c0ca 100644
--- a/packages/devtools_app/test/shared/primitives/utils_test.dart
+++ b/packages/devtools_app/test/shared/primitives/utils_test.dart
@@ -704,135 +704,3 @@
   @override
   String toString() => '$from - $subtract';
 }
-
-// This was generated from a canvas with font size 14.0.
-const asciiMeasurements = [
-  0,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  0,
-  3.8896484375,
-  3.8896484375,
-  3.8896484375,
-  3.8896484375,
-  3.8896484375,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  4.6619873046875,
-  0,
-  4.6619873046875,
-  4.6619873046875,
-  3.8896484375,
-  3.8896484375,
-  4.9697265625,
-  7.7861328125,
-  7.7861328125,
-  12.4482421875,
-  9.337890625,
-  2.6728515625,
-  4.662109375,
-  4.662109375,
-  5.4482421875,
-  8.17578125,
-  3.8896484375,
-  4.662109375,
-  3.8896484375,
-  3.8896484375,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  3.8896484375,
-  3.8896484375,
-  8.17578125,
-  8.17578125,
-  8.17578125,
-  7.7861328125,
-  14.2119140625,
-  9.337890625,
-  9.337890625,
-  10.1103515625,
-  10.1103515625,
-  9.337890625,
-  8.5517578125,
-  10.8896484375,
-  10.1103515625,
-  3.8896484375,
-  7,
-  9.337890625,
-  7.7861328125,
-  11.662109375,
-  10.1103515625,
-  10.8896484375,
-  9.337890625,
-  10.8896484375,
-  10.1103515625,
-  9.337890625,
-  8.5517578125,
-  10.1103515625,
-  9.337890625,
-  13.2138671875,
-  9.337890625,
-  9.337890625,
-  8.5517578125,
-  3.8896484375,
-  3.8896484375,
-  3.8896484375,
-  6.5693359375,
-  7.7861328125,
-  4.662109375,
-  7.7861328125,
-  7.7861328125,
-  7,
-  7.7861328125,
-  7.7861328125,
-  3.8896484375,
-  7.7861328125,
-  7.7861328125,
-  3.1103515625,
-  3.1103515625,
-  7,
-  3.1103515625,
-  11.662109375,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  7.7861328125,
-  4.662109375,
-  7,
-  3.8896484375,
-  7.7861328125,
-  7,
-  10.1103515625,
-  7,
-  7,
-  7,
-  4.67578125,
-  3.63671875,
-  4.67578125,
-  8.17578125,
-  0,
-];
diff --git a/packages/devtools_app/test/test_infra/fixtures/debugging_app.dart b/packages/devtools_app/test/test_infra/fixtures/debugging_app.dart
deleted file mode 100644
index bb732d9..0000000
--- a/packages/devtools_app/test/test_infra/fixtures/debugging_app.dart
+++ /dev/null
@@ -1,40 +0,0 @@
-// Copyright 2019 The Flutter Authors
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file or at https://developers.google.com/open-source/licenses/bsd.
-
-// ignore_for_file: avoid_print
-
-import 'dart:async';
-
-void main() {
-  print('starting debugging app');
-
-  final cat = Cat('Fluffy');
-
-  void run() {
-    Timer(const Duration(milliseconds: 100), () {
-      cat.performAction();
-
-      run();
-    });
-  }
-
-  run();
-}
-
-class Cat {
-  Cat(this.name);
-
-  final String name;
-
-  String get type => 'cat';
-
-  int actionCount = 0;
-
-  void performAction() {
-    String actionStr = 'catAction';
-    actionStr = '$actionStr!';
-
-    actionCount++; // breakpoint
-  }
-}
diff --git a/packages/devtools_app/test/test_infra/fixtures/logging_app.dart b/packages/devtools_app/test/test_infra/fixtures/logging_app.dart
deleted file mode 100644
index afe3700..0000000
--- a/packages/devtools_app/test/test_infra/fixtures/logging_app.dart
+++ /dev/null
@@ -1,38 +0,0 @@
-// Copyright 2018 The Flutter Authors
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file or at https://developers.google.com/open-source/licenses/bsd.
-
-// ignore_for_file: avoid_print
-
-import 'dart:async';
-import 'dart:developer';
-import 'dart:io';
-
-// Allow a test driver to communicate with this app through the controller.
-final controller = Controller();
-
-void main() {
-  print('starting logging app');
-  log('starting logging app');
-
-  // Don't exit until it's indicated we should by the controller.
-  Timer(const Duration(days: 1), () {});
-}
-
-class Controller {
-  int count = 0;
-
-  void emitLog() {
-    count++;
-
-    print('emitLog called');
-    log('emit log $count', name: 'logging');
-  }
-
-  void shutdown() {
-    print('stopping app');
-    log('stopping app');
-
-    exit(0);
-  }
-}
diff --git a/packages/devtools_app/test/test_infra/fixtures/networking_app/bin/main.dart b/packages/devtools_app/test/test_infra/fixtures/networking_app/bin/main.dart
index 73d1d30..c875688 100644
--- a/packages/devtools_app/test/test_infra/fixtures/networking_app/bin/main.dart
+++ b/packages/devtools_app/test/test_infra/fixtures/networking_app/bin/main.dart
@@ -100,11 +100,6 @@
 
   final _dio = Dio();
 
-  void close() {
-    _client.close(force: true);
-    _dio.close(force: true);
-  }
-
   void get() async {
     print('Sending GET...');
     final request = await _client.getUrl(_uri);
diff --git a/packages/devtools_app/test/test_infra/flutter_test_driver.dart b/packages/devtools_app/test/test_infra/flutter_test_driver.dart
index 99eda70..5aa28a6 100644
--- a/packages/devtools_app/test/test_infra/flutter_test_driver.dart
+++ b/packages/devtools_app/test/test_infra/flutter_test_driver.dart
@@ -43,17 +43,9 @@
   final errorBuffer = StringBuffer();
   late String lastResponse;
   late Uri _vmServiceWsUri;
-  bool hasExited = false;
 
   VmServiceWrapper? vmService;
 
-  String get lastErrorInfo => errorBuffer.toString();
-
-  Stream<String> get stderr => stderrController.stream;
-  Stream<String> get stdout => stdoutController.stream;
-
-  Uri get vmServiceUri => _vmServiceWsUri;
-
   String _debugPrint(String msg) {
     const maxLength = 500;
     final truncatedMsg = msg.length > maxLength
@@ -94,7 +86,6 @@
     unawaited(
       proc.exitCode.then((int code) {
         _debugPrint('Process exited ($code)');
-        hasExited = true;
       }),
     );
     transformToLines(
diff --git a/packages/devtools_app/test/test_infra/flutter_test_environment.dart b/packages/devtools_app/test/test_infra/flutter_test_environment.dart
index 812853c..bb81e3e 100644
--- a/packages/devtools_app/test/test_infra/flutter_test_environment.dart
+++ b/packages/devtools_app/test/test_infra/flutter_test_environment.dart
@@ -71,11 +71,6 @@
   /// test/my_test.dart`).
   final String _flutterExe;
 
-  // This function will be called after we have ran the Flutter app and the
-  // vmService is opened.
-  Future<void> Function()? _afterNewSetup;
-  set afterNewSetup(Future<void> Function() f) => _afterNewSetup = f;
-
   // This function will be called for every call to [setupEnvironment], even
   // when the setup is not forced or triggered by a new FlutterRunConfiguration.
   Future<void> Function()? _afterEverySetup;
@@ -89,12 +84,6 @@
   set beforeEveryTearDown(Future<void> Function() f) =>
       _beforeEveryTearDown = f;
 
-  // The function will be called before the final forced teardown at the end
-  // of the test suite (which will then stop the Flutter app).
-  Future<void> Function()? _beforeFinalTearDown;
-  set beforeFinalTearDown(Future<void> Function() f) =>
-      _beforeFinalTearDown = f;
-
   bool _needsSetup = true;
 
   Completer<bool>? _setupInProgress;
@@ -173,8 +162,6 @@
       } finally {
         _setupInProgress!.complete(!_needsSetup);
       }
-
-      if (_afterNewSetup != null) await _afterNewSetup!();
     }
     if (_afterEverySetup != null) await _afterEverySetup!();
   }
@@ -192,8 +179,6 @@
       return;
     }
 
-    if (_beforeFinalTearDown != null) await _beforeFinalTearDown!();
-
     await serviceConnection.serviceManager.manuallyDisconnect();
 
     await _service.allFuturesCompleted.timeout(
diff --git a/packages/devtools_app/test/test_infra/matchers/matchers.dart b/packages/devtools_app/test/test_infra/matchers/matchers.dart
index 6005a45..e132370 100644
--- a/packages/devtools_app/test/test_infra/matchers/matchers.dart
+++ b/packages/devtools_app/test/test_infra/matchers/matchers.dart
@@ -34,14 +34,6 @@
   return node.toDiagnosticsNode().toStringDeep();
 }
 
-String treeToDebugStringTruncated(RemoteDiagnosticsNode node, int maxLines) {
-  List<String> lines = node.toDiagnosticsNode().toStringDeep().split('\n');
-  if (lines.length > maxLines) {
-    lines = lines.take(maxLines).toList()..add('...');
-  }
-  return lines.join('\n');
-}
-
 /// Asserts that a [path] matches a golden file after normalizing likely hash
 /// codes.
 ///
diff --git a/packages/devtools_app/test/test_infra/scenes/memory/diff_snapshot.dart b/packages/devtools_app/test/test_infra/scenes/memory/diff_snapshot.dart
index aa79a9d..ce34c5f 100644
--- a/packages/devtools_app/test/test_infra/scenes/memory/diff_snapshot.dart
+++ b/packages/devtools_app/test/test_infra/scenes/memory/diff_snapshot.dart
@@ -60,6 +60,4 @@
       ClassFilter(filterType: ClassFilterType.showAll, except: '', only: ''),
     );
   }
-
-  void tearDown() {}
 }
diff --git a/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_service/simulated_editor.dart b/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_service/simulated_editor.dart
index a762658..d2d66ef 100644
--- a/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_service/simulated_editor.dart
+++ b/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_service/simulated_editor.dart
@@ -35,11 +35,6 @@
     return editor;
   }
 
-  void dispose() {
-    unawaited(_logger.close());
-    unawaited(close());
-  }
-
   /// The URI of the DTD instance we are connecting/connected to.
   final Uri _dtdUri;
 
@@ -49,6 +44,7 @@
   DartToolingDaemon? _dtd;
 
   /// A controller for emitting to [log].
+  // ignore: dispose-class-fields, only used in tests.
   final _logger = StreamController<String>();
 
   /// A stream of protocol traffic between the editor and DTD (or postMessage
@@ -209,10 +205,6 @@
     await _postEvent(DebugSessionStartedEvent(debugSession: debugSession));
   }
 
-  void sendDebugSessionChanged(EditorDebugSession debugSession) async {
-    await _postEvent(DebugSessionChangedEvent(debugSession: debugSession));
-  }
-
   void sendDebugSessionStopped(EditorDebugSession debugSession) async {
     await _postEvent(DebugSessionStoppedEvent(debugSessionId: debugSession.id));
   }
diff --git a/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_sidebar.dart b/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_sidebar.dart
index 57cbd4f..bdf9512 100644
--- a/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_sidebar.dart
+++ b/packages/devtools_app/test/test_infra/scenes/standalone_ui/editor_sidebar.dart
@@ -9,7 +9,6 @@
 import 'package:devtools_app_shared/service.dart';
 import 'package:devtools_app_shared/ui.dart';
 import 'package:devtools_app_shared/utils.dart';
-import 'package:dtd/dtd.dart';
 import 'package:flutter/material.dart';
 import 'package:stager/stager.dart';
 
@@ -24,7 +23,6 @@
 /// flutter run -t test/test_infra/scenes/standalone_ui/editor_sidebar.stager_app.g.dart -d chrome
 class EditorSidebarScene extends Scene {
   late Stream<String> clientLog;
-  late DartToolingDaemon clientDtd;
   late SimulatedEditor editor;
 
   @override
diff --git a/packages/devtools_app/test/test_infra/scenes/standalone_ui/shared/utils.dart b/packages/devtools_app/test/test_infra/scenes/standalone_ui/shared/utils.dart
index 0156a7f..bfda887 100644
--- a/packages/devtools_app/test/test_infra/scenes/standalone_ui/shared/utils.dart
+++ b/packages/devtools_app/test/test_infra/scenes/standalone_ui/shared/utils.dart
@@ -9,10 +9,6 @@
 import 'package:stream_channel/stream_channel.dart';
 import 'package:web_socket_channel/web_socket_channel.dart';
 
-/// A record of a [StreamChannel] and a [Stream] of logs of protocol traffic
-/// in both directions across it.
-typedef LoggedChannel = ({StreamChannel<String> channel, Stream<String> log});
-
 /// Connects to the websocket at [wsUri] and returns a [StreamSink<String>].
 ///
 /// All traffic is logged into [sink].
diff --git a/packages/devtools_app/test/test_infra/test_data/deep_link/fake_responses.dart b/packages/devtools_app/test/test_infra/test_data/deep_link/fake_responses.dart
index 1f8ebc5..beaf9c5 100644
--- a/packages/devtools_app/test/test_infra/test_data/deep_link/fake_responses.dart
+++ b/packages/devtools_app/test/test_infra/test_data/deep_link/fake_responses.dart
@@ -429,18 +429,6 @@
 }
 ''';
 
-const androidDeepLinkWithPathErrors = '''{
-      "host": "example.com",
-      "path": "/path",
-      "intentFilterCheck": {
-        "hasBrowsableCategory": false,
-        "hasActionView": true,
-        "hasDefaultCategory": true,
-        "hasAutoVerify": true
-      }
-    }
-''';
-
 const defaultDomain = 'example.com';
 
 String androidDeepLinkJson(
diff --git a/packages/devtools_app/test/test_infra/test_data/memory/heap/heap_data.dart b/packages/devtools_app/test/test_infra/test_data/memory/heap/heap_data.dart
index 867dff6..be03124 100644
--- a/packages/devtools_app/test/test_infra/test_data/memory/heap/heap_data.dart
+++ b/packages/devtools_app/test/test_infra/test_data/memory/heap/heap_data.dart
@@ -32,15 +32,6 @@
   }
 }
 
-class MockedHeapTest extends HeapTest {
-  MockedHeapTest({required super.appClassName});
-
-  @override
-  Future<HeapSnapshotGraph> loadHeap() {
-    throw UnimplementedError();
-  }
-}
-
 /// Provides test snapshots from pre-saved goldens.
 class HeapGraphLoaderGoldens implements HeapGraphLoader {
   int _nextIndex = 0;
diff --git a/packages/devtools_app/test/test_infra/test_data/performance/sample_performance_data.dart b/packages/devtools_app/test/test_infra/test_data/performance/sample_performance_data.dart
index 8a9362c..e453bb5 100644
--- a/packages/devtools_app/test/test_infra/test_data/performance/sample_performance_data.dart
+++ b/packages/devtools_app/test/test_infra/test_data/performance/sample_performance_data.dart
@@ -140,32 +140,6 @@
         ..setEventFlow(uiEvent)
         ..setEventFlow(rasterEvent);
 
-  static const uiEventAsString =
-      '''  Animator::BeginFrame [713834379092 μs - 713834379102 μs]
-''';
-
-  static const rasterEventAsString =
-      '''  Rasterizer::DoDraw [713836088591 μs - 713836108931 μs]
-    Rasterizer::DrawToSurfaces [713836088592 μs - 713836108917 μs]
-      GPUSurfaceMetalImpeller::AcquireFrame [713836088607 μs - 713836093553 μs]
-        SurfaceMTL::WrapCurrentMetalLayerDrawable [713836088654 μs - 713836093545 μs]
-          WaitForNextDrawable [713836088655 μs - 713836093541 μs]
-      CompositorContext::ScopedFrame::Raster [713836093557 μs - 713836093615 μs]
-        LayerTree::Preroll [713836093580 μs - 713836093597 μs]
-        IOSExternalViewEmbedder::PostPrerollAction [713836093598 μs - 713836093598 μs]
-        LayerTree::Paint [713836093599 μs - 713836093615 μs]
-      SurfaceFrame::Submit [713836093616 μs - 713836108864 μs]
-        SurfaceFrame::BuildDisplayList [713836093616 μs - 713836093621 μs]
-        DisplayListDispatcher::EndRecordingAsPicture [713836094185 μs - 713836094188 μs]
-        Renderer::Render [713836094188 μs - 713836108846 μs]
-          EntityPass::OnRender [713836094556 μs - 713836108700 μs]
-            CreateGlyphAtlas [713836099800 μs - 713836108025 μs]
-              CanAppendToExistingAtlas [713836099807 μs - 713836099810 μs]
-              OptimumAtlasSizeForFontGlyphPairs [713836099811 μs - 713836099835 μs]
-              CreateAtlasBitmap [713836099845 μs - 713836103975 μs]
-              UploadGlyphTextureAtlas [713836103979 μs - 713836108020 μs]
-''';
-
   static final uiEvent = animatorBeginFrameEvent;
   static final animatorBeginFrameEvent = testTimelineEvent(
     name: 'Animator::BeginFrame',
@@ -385,40 +359,6 @@
     'vsyncOverhead': 12625,
   };
 
-  static const uiEventAsString =
-      '''  Animator::BeginFrame [713836200161 μs - 713836206957 μs]
-    LAYOUT (root) [713836202351 μs - 713836202383 μs]
-      LAYOUT [713836202373 μs - 713836202380 μs]
-    UPDATING COMPOSITING BITS (root) [713836202387 μs - 713836202402 μs]
-      UPDATING COMPOSITING BITS [713836202397 μs - 713836202400 μs]
-    PAINT (root) [713836202408 μs - 713836202429 μs]
-      PAINT [713836202422 μs - 713836202427 μs]
-    COMPOSITING [713836202440 μs - 713836206727 μs]
-      Animator::Render [713836206671 μs - 713836206714 μs]
-    SEMANTICS (root) [713836206752 μs - 713836206828 μs]
-      SEMANTICS [713836206785 μs - 713836206825 μs]
-    FINALIZE TREE [713836206834 μs - 713836206878 μs]
-    POST_FRAME [713836206903 μs - 713836206925 μs]
-''';
-
-  static const rasterEventAsString =
-      '''  Rasterizer::DoDraw [713836206748 μs - 713836211160 μs]
-    Rasterizer::DrawToSurfaces [713836206750 μs - 713836211143 μs]
-      GPUSurfaceMetalImpeller::AcquireFrame [713836206755 μs - 713836210203 μs]
-        SurfaceMTL::WrapCurrentMetalLayerDrawable [713836206763 μs - 713836210196 μs]
-          WaitForNextDrawable [713836206764 μs - 713836210193 μs]
-      CompositorContext::ScopedFrame::Raster [713836210206 μs - 713836210251 μs]
-        LayerTree::Preroll [713836210219 μs - 713836210225 μs]
-        IOSExternalViewEmbedder::PostPrerollAction [713836210226 μs - 713836210226 μs]
-        LayerTree::Paint [713836210240 μs - 713836210250 μs]
-      SurfaceFrame::Submit [713836210251 μs - 713836211118 μs]
-        SurfaceFrame::BuildDisplayList [713836210251 μs - 713836210254 μs]
-        DisplayListDispatcher::EndRecordingAsPicture [713836210613 μs - 713836210616 μs]
-        Renderer::Render [713836210616 μs - 713836211105 μs]
-          EntityPass::OnRender [713836210642 μs - 713836211061 μs]
-            CreateGlyphAtlas [713836210893 μs - 713836210899 μs]
-''';
-
   static final uiEvent = animatorBeginFrameEvent
     ..addAllChildren([
       layoutRootEvent..addChild(layoutEvent),
@@ -943,40 +883,6 @@
     'vsyncOverhead': 1108,
   };
 
-  static const uiEventAsString =
-      '''  Animator::BeginFrame [713836329948 μs - 713836331003 μs]
-    LAYOUT (root) [713836330239 μs - 713836330280 μs]
-      LAYOUT [713836330262 μs - 713836330277 μs]
-    UPDATING COMPOSITING BITS (root) [713836330284 μs - 713836330307 μs]
-      UPDATING COMPOSITING BITS [713836330302 μs - 713836330306 μs]
-    PAINT (root) [713836330324 μs - 713836330348 μs]
-      PAINT [713836330337 μs - 713836330346 μs]
-    COMPOSITING [713836330357 μs - 713836330723 μs]
-      Animator::Render [713836330691 μs - 713836330716 μs]
-    SEMANTICS (root) [713836330738 μs - 713836330844 μs]
-      SEMANTICS [713836330783 μs - 713836330842 μs]
-    FINALIZE TREE [713836330848 μs - 713836330920 μs]
-    POST_FRAME [713836330964 μs - 713836330989 μs]
-''';
-
-  static const rasterEventAsString =
-      '''  Rasterizer::DoDraw [713836330790 μs - 713836331692 μs]
-    Rasterizer::DrawToSurfaces [713836330791 μs - 713836331684 μs]
-      GPUSurfaceMetalImpeller::AcquireFrame [713836330801 μs - 713836330844 μs]
-        SurfaceMTL::WrapCurrentMetalLayerDrawable [713836330814 μs - 713836330839 μs]
-          WaitForNextDrawable [713836330817 μs - 713836330836 μs]
-      CompositorContext::ScopedFrame::Raster [713836330846 μs - 713836330888 μs]
-        LayerTree::Preroll [713836330862 μs - 713836330870 μs]
-        IOSExternalViewEmbedder::PostPrerollAction [713836330870 μs - 713836330870 μs]
-        LayerTree::Paint [713836330870 μs - 713836330888 μs]
-      SurfaceFrame::Submit [713836330888 μs - 713836331669 μs]
-        SurfaceFrame::BuildDisplayList [713836330889 μs - 713836330894 μs]
-        DisplayListDispatcher::EndRecordingAsPicture [713836331274 μs - 713836331276 μs]
-        Renderer::Render [713836331277 μs - 713836331661 μs]
-          EntityPass::OnRender [713836331302 μs - 713836331633 μs]
-            CreateGlyphAtlas [713836331499 μs - 713836331505 μs]
-''';
-
   static final uiEvent = animatorBeginFrameEvent
     ..addAllChildren([
       layoutRootEvent..addChild(layoutEvent),
diff --git a/packages/devtools_app/test/test_infra/utils/deep_links_utils.dart b/packages/devtools_app/test/test_infra/utils/deep_links_utils.dart
index 4242f4e..509a0b3 100644
--- a/packages/devtools_app/test/test_infra/utils/deep_links_utils.dart
+++ b/packages/devtools_app/test/test_infra/utils/deep_links_utils.dart
@@ -56,7 +56,6 @@
 
   List<String> fakeAndroidDeepLinks = [];
   bool hasAndroidDomainErrors = false;
-  bool hasAndroidPathErrors = false;
   String iosValidationResponse = '';
   List<String> fakeIosDomains = [];
 
diff --git a/packages/devtools_app/test/test_infra/utils/extent_delegate_utils.dart b/packages/devtools_app/test/test_infra/utils/extent_delegate_utils.dart
index 6893cf1..e3ef8c0 100644
--- a/packages/devtools_app/test/test_infra/utils/extent_delegate_utils.dart
+++ b/packages/devtools_app/test/test_infra/utils/extent_delegate_utils.dart
@@ -16,6 +16,7 @@
   });
 
   late RenderSliverExtentDelegateBoxAdaptor _renderObject;
+  // ignore: unused-code, used in asserts.
   bool _renderObjectInitialized = false;
   List<RenderBox> children;
 
diff --git a/packages/devtools_app/test/test_infra/utils/rendering_tester.dart b/packages/devtools_app/test/test_infra/utils/rendering_tester.dart
index 5b05498..b74d9fc 100644
--- a/packages/devtools_app/test/test_infra/utils/rendering_tester.dart
+++ b/packages/devtools_app/test/test_infra/utils/rendering_tester.dart
@@ -34,8 +34,7 @@
   ///
   /// If [onErrors] is not null, it is called if [FlutterError] caught any errors
   /// while drawing the frame. If [onErrors] is null and [FlutterError] caught at least
-  /// one error, this function fails the test. A test may override [onErrors] and
-  /// inspect errors using [takeFlutterErrorDetails].
+  /// one error, this function fails the test.
   ///
   /// Errors caught between frames will cause the test to fail unless
   /// [FlutterError.onError] has been overridden.
@@ -119,83 +118,11 @@
   /// A function called after drawing a frame if [FlutterError] caught any errors.
   ///
   /// This function is expected to inspect these errors and decide whether they
-  /// are expected or not. Use [takeFlutterErrorDetails] to take one error at a
-  /// time, or [takeAllFlutterErrorDetails] to iterate over all errors.
+  /// are expected or not.
   VoidCallback? onErrors;
 
-  /// Returns the error least recently caught by [FlutterError] and removes it
-  /// from the list of captured errors.
-  ///
-  /// Returns null if no errors were captures, or if the list was exhausted by
-  /// calling this method repeatedly.
-  FlutterErrorDetails? takeFlutterErrorDetails() {
-    if (_errors.isEmpty) {
-      return null;
-    }
-    return _errors.removeAt(0);
-  }
-
-  /// Returns all error details caught by [FlutterError] from least recently caught to
-  /// most recently caught, and removes them from the list of captured errors.
-  ///
-  /// The returned iterable takes errors lazily. If, for example, you iterate over 2
-  /// errors, but there are 5 errors total, this binding will still fail the test.
-  /// Tests are expected to take and inspect all errors.
-  Iterable<FlutterErrorDetails> takeAllFlutterErrorDetails() sync* {
-    // sync* and yield are used for lazy evaluation. Otherwise, the list would be
-    // drained eagerly and allow a test pass with unexpected errors.
-    while (_errors.isNotEmpty) {
-      yield _errors.removeAt(0);
-    }
-  }
-
-  /// Returns all exceptions caught by [FlutterError] from least recently caught to
-  /// most recently caught, and removes them from the list of captured errors.
-  ///
-  /// The returned iterable takes errors lazily. If, for example, you iterate over 2
-  /// errors, but there are 5 errors total, this binding will still fail the test.
-  /// Tests are expected to take and inspect all errors.
-  Iterable<Object?> takeAllFlutterExceptions() sync* {
-    // sync* and yield are used for lazy evaluation. Otherwise, the list would be
-    // drained eagerly and allow a test pass with unexpected errors.
-    while (_errors.isNotEmpty) {
-      yield _errors.removeAt(0).exception;
-    }
-  }
-
   EnginePhase phase = EnginePhase.composite;
 
-  /// Pumps a frame and runs its entire life cycle.
-  ///
-  /// This method runs all of the [SchedulerPhase]s in a frame, this is useful
-  /// to test [SchedulerPhase.postFrameCallbacks].
-  void pumpCompleteFrame() {
-    final FlutterExceptionHandler? oldErrorHandler = FlutterError.onError;
-    FlutterError.onError = _errors.add;
-    try {
-      TestRenderingFlutterBinding.instance.handleBeginFrame(null);
-      TestRenderingFlutterBinding.instance.handleDrawFrame();
-    } finally {
-      FlutterError.onError = oldErrorHandler;
-      if (_errors.isNotEmpty) {
-        if (onErrors != null) {
-          onErrors!();
-          if (_errors.isNotEmpty) {
-            _errors.forEach(FlutterError.dumpErrorToConsole);
-            fail(
-              'There are more errors than the test inspected using TestRenderingFlutterBinding.takeFlutterErrorDetails.',
-            );
-          }
-        } else {
-          _errors.forEach(FlutterError.dumpErrorToConsole);
-          fail(
-            'Caught error while rendering frame. See preceding logs for details.',
-          );
-        }
-      }
-    }
-  }
-
   @override
   void drawFrame() {
     assert(
@@ -315,20 +242,6 @@
   TestRenderingFlutterBinding.instance.drawFrame();
 }
 
-class TestCallbackPainter extends CustomPainter {
-  const TestCallbackPainter({required this.onPaint});
-
-  final VoidCallback onPaint;
-
-  @override
-  void paint(Canvas canvas, Size size) {
-    onPaint();
-  }
-
-  @override
-  bool shouldRepaint(TestCallbackPainter oldPainter) => true;
-}
-
 class RenderSizedBox extends RenderBox {
   RenderSizedBox(this._size);
 
@@ -368,70 +281,3 @@
   @override
   bool hitTestSelf(Offset position) => true;
 }
-
-class TestClipPaintingContext extends PaintingContext {
-  TestClipPaintingContext() : super(ContainerLayer(), Rect.zero);
-
-  @override
-  ClipRectLayer? pushClipRect(
-    bool needsCompositing,
-    Offset offset,
-    Rect clipRect,
-    PaintingContextCallback painter, {
-    Clip clipBehavior = Clip.hardEdge,
-    ClipRectLayer? oldLayer,
-  }) {
-    this.clipBehavior = clipBehavior;
-    return null;
-  }
-
-  Clip clipBehavior = Clip.none;
-}
-
-class TestPushLayerPaintingContext extends PaintingContext {
-  TestPushLayerPaintingContext() : super(ContainerLayer(), Rect.zero);
-
-  final pushedLayers = <ContainerLayer>[];
-
-  @override
-  void pushLayer(
-    ContainerLayer childLayer,
-    PaintingContextCallback painter,
-    Offset offset, {
-    Rect? childPaintBounds,
-  }) {
-    pushedLayers.add(childLayer);
-    super.pushLayer(
-      childLayer,
-      painter,
-      offset,
-      childPaintBounds: childPaintBounds,
-    );
-  }
-}
-
-// Absorbs errors that don't have "overflowed" in their error details.
-void absorbOverflowedErrors() {
-  final errorDetails = TestRenderingFlutterBinding.instance
-      .takeAllFlutterErrorDetails();
-  final filtered = errorDetails.where((FlutterErrorDetails details) {
-    return !details.toString().contains('overflowed');
-  });
-  if (filtered.isNotEmpty) {
-    filtered.forEach(FlutterError.reportError);
-  }
-}
-
-// Reports any FlutterErrors.
-void expectNoFlutterErrors() {
-  final errorDetails = TestRenderingFlutterBinding.instance
-      .takeAllFlutterErrorDetails();
-  errorDetails.forEach(FlutterError.reportError);
-}
-
-RenderConstrainedBox get box200x200 => RenderConstrainedBox(
-  additionalConstraints: const BoxConstraints.tightFor(
-    height: 200.0,
-    width: 200.0,
-  ),
-);
diff --git a/packages/devtools_shared/lib/src/server/file_system.dart b/packages/devtools_shared/lib/src/server/file_system.dart
index 450790b..6391808 100644
--- a/packages/devtools_shared/lib/src/server/file_system.dart
+++ b/packages/devtools_shared/lib/src/server/file_system.dart
@@ -12,7 +12,7 @@
 import 'devtools_store.dart';
 
 /// The real, local file system, which can be avoided in tests.
-const FileSystem fileSystem = LocalFileSystem();
+const fileSystem = LocalFileSystem();
 
 extension FileSystemExtension on FileSystem {
   static String get _userHomeDir {
diff --git a/packages/devtools_shared/test/helpers/helpers.dart b/packages/devtools_shared/test/helpers/helpers.dart
index 3f174aa..8c03895 100644
--- a/packages/devtools_shared/test/helpers/helpers.dart
+++ b/packages/devtools_shared/test/helpers/helpers.dart
@@ -62,45 +62,60 @@
 }
 
 class TestDartApp {
+  TestDartApp() {
+    directory = Directory(
+      'tmp/test_app_${DateTime.now().millisecondsSinceEpoch}',
+    );
+  }
   static final dartVMServiceRegExp = RegExp(
     r'The Dart VM service is listening on (http://127.0.0.1:.*)',
   );
 
-  final directory = Directory('tmp/test_app');
+  late final Directory directory;
 
   Process? process;
+  StreamSubscription<String>? _stdoutSub;
+  StreamSubscription<String>? _stderrSub;
 
   Future<String> start() async {
     await _initTestApp();
     process = await Process.start(Platform.resolvedExecutable, [
       '--observe=0',
-      'run',
       'bin/main.dart',
     ], workingDirectory: directory.path);
 
     final serviceUriCompleter = Completer<String>();
-    late StreamSubscription sub;
-    sub = process!.stdout
+    _stdoutSub = process!.stdout
         .transform(utf8.decoder)
         .transform(const LineSplitter())
-        .listen((line) async {
-          if (line.contains(dartVMServiceRegExp)) {
-            await sub.cancel();
+        .listen((line) {
+          if (!serviceUriCompleter.isCompleted &&
+              line.contains(dartVMServiceRegExp)) {
             serviceUriCompleter.complete(
               dartVMServiceRegExp.firstMatch(line)!.group(1),
             );
           }
         });
+
+    _stderrSub = process!.stderr
+        .transform(utf8.decoder)
+        .transform(const LineSplitter())
+        .listen((line) {
+          // ignore: avoid_print, deliberate print to monitor errors.
+          print('TestDartApp stderr: $line');
+        });
+
     return await serviceUriCompleter.future.timeout(
       const Duration(seconds: 5),
-      onTimeout: () async {
-        await sub.cancel();
+      onTimeout: () {
         return '';
       },
     );
   }
 
   Future<void> kill() async {
+    await _stdoutSub?.cancel();
+    await _stderrSub?.cancel();
     process?.kill();
     await process?.exitCode;
     process = null;
@@ -110,6 +125,7 @@
   Future<void> _initTestApp() async {
     await deleteDirectoryWithRetry(directory);
     directory.createSync(recursive: true);
+    Directory(path.join(directory.path, '.dart_tool')).createSync();
 
     final mainFile = File(path.join(directory.path, 'bin', 'main.dart'))
       ..createSync(recursive: true);
diff --git a/packages/devtools_shared/test/server/general_api_test.dart b/packages/devtools_shared/test/server/general_api_test.dart
index c2bb000..1c57223 100644
--- a/packages/devtools_shared/test/server/general_api_test.dart
+++ b/packages/devtools_shared/test/server/general_api_test.dart
@@ -6,7 +6,6 @@
 
 import 'package:devtools_shared/devtools_server.dart';
 import 'package:devtools_shared/devtools_shared.dart';
-import 'package:devtools_shared/devtools_test_utils.dart';
 import 'package:devtools_shared/src/extensions/extension_manager.dart';
 import 'package:devtools_shared/src/server/server_api.dart' as server;
 import 'package:dtd/dtd.dart';
@@ -157,8 +156,6 @@
         setUp(() async {
           app = TestDartApp();
           vmServiceUriString = await app!.start();
-          // Await a short delay to give the VM a chance to initialize.
-          await delay(duration: const Duration(milliseconds: 2500));
           expect(vmServiceUriString, isNotEmpty);
         });
 
@@ -171,13 +168,21 @@
         test('succeeds for a connect event', () async {
           final vmServiceUri = normalizeVmServiceUri(vmServiceUriString!);
           expect(vmServiceUri, isNotNull);
-          final response =
-              await server.VmServiceHandler.detectRootPackageForVmService(
-                vmServiceUriAsString: vmServiceUriString!,
-                vmServiceUri: vmServiceUri!,
-                connected: true,
-                dtd: testDtdConnection!,
-              );
+          late server.DetectRootPackageResponse response;
+          await runWithRetry(
+            callback: () async {
+              response =
+                  await server.VmServiceHandler.detectRootPackageForVmService(
+                    vmServiceUriAsString: vmServiceUriString!,
+                    vmServiceUri: vmServiceUri!,
+                    connected: true,
+                    dtd: testDtdConnection!,
+                  );
+              if (!response.success) throw Exception('VM not ready');
+            },
+            maxRetries: 20,
+            retryDelay: const Duration(milliseconds: 500),
+          );
           expect(response.success, true);
           expect(response.message, isNull);
           expect(response.uri, isNotNull);
@@ -200,13 +205,21 @@
           () async {
             final vmServiceUri = normalizeVmServiceUri(vmServiceUriString!);
             expect(vmServiceUri, isNotNull);
-            final response =
-                await server.VmServiceHandler.detectRootPackageForVmService(
-                  vmServiceUriAsString: vmServiceUriString!,
-                  vmServiceUri: vmServiceUri!,
-                  connected: true,
-                  dtd: testDtdConnection!,
-                );
+            late server.DetectRootPackageResponse response;
+            await runWithRetry(
+              callback: () async {
+                response =
+                    await server.VmServiceHandler.detectRootPackageForVmService(
+                      vmServiceUriAsString: vmServiceUriString!,
+                      vmServiceUri: vmServiceUri!,
+                      connected: true,
+                      dtd: testDtdConnection!,
+                    );
+                if (!response.success) throw Exception('VM not ready');
+              },
+              maxRetries: 20,
+              retryDelay: const Duration(milliseconds: 500),
+            );
             expect(response.success, true);
             expect(response.message, isNull);
             expect(response.uri, isNotNull);
@@ -215,7 +228,7 @@
             final disconnectResponse =
                 await server.VmServiceHandler.detectRootPackageForVmService(
                   vmServiceUriAsString: vmServiceUriString!,
-                  vmServiceUri: vmServiceUri,
+                  vmServiceUri: vmServiceUri!,
                   connected: false,
                   dtd: testDtdConnection!,
                 );
diff --git a/packages/devtools_test/lib/src/mocks/fake_vm_service_wrapper.dart b/packages/devtools_test/lib/src/mocks/fake_vm_service_wrapper.dart
index 0df17c7..c687bb6 100644
--- a/packages/devtools_test/lib/src/mocks/fake_vm_service_wrapper.dart
+++ b/packages/devtools_test/lib/src/mocks/fake_vm_service_wrapper.dart
@@ -128,25 +128,27 @@
   }
 
   @override
-  Future<UriList> lookupPackageUris(
-    String isolateId,
-    List<String> uris,
-  ) => Future.syncValue(UriList(
-    uris: _resolvedUriMap != null
-        ? (uris.map((e) => _resolvedUriMap[e]).toList())
-        : null
-  ));
+  Future<UriList> lookupPackageUris(String isolateId, List<String> uris) =>
+      Future.syncValue(
+        UriList(
+          uris: _resolvedUriMap != null
+              ? (uris.map((e) => _resolvedUriMap[e]).toList())
+              : null,
+        ),
+      );
 
   @override
   Future<UriList> lookupResolvedPackageUris(
     String isolateId,
     List<String> uris, {
     bool? local,
-  })  => Future.syncValue(UriList(
-    uris: _reverseResolvedUriMap != null
-        ? (uris.map((e) => _reverseResolvedUriMap[e]).toList())
-        : null,
-  ));
+  }) => Future.syncValue(
+    UriList(
+      uris: _reverseResolvedUriMap != null
+          ? (uris.map((e) => _reverseResolvedUriMap[e]).toList())
+          : null,
+    ),
+  );
 
   @override
   String get wsUri => 'ws://127.0.0.1:56137/ISsyt6ki0no=/ws';
diff --git a/tool/cpu_sample_intervals.dart b/tool/cpu_sample_intervals.dart
index f6b2f07..10d50bc 100644
--- a/tool/cpu_sample_intervals.dart
+++ b/tool/cpu_sample_intervals.dart
@@ -26,10 +26,10 @@
 
   final List<int> deltas = [];
   for (int i = 0; i < cpuSampleTraceEvents.length - 1; i++) {
-    final Map<String, dynamic> current =
-        (cpuSampleTraceEvents[i] as Map).cast<String, dynamic>();
-    final Map<String, dynamic> next =
-        (cpuSampleTraceEvents[i + 1] as Map).cast<String, dynamic>();
+    final Map<String, dynamic> current = (cpuSampleTraceEvents[i] as Map)
+        .cast<String, dynamic>();
+    final Map<String, dynamic> next = (cpuSampleTraceEvents[i + 1] as Map)
+        .cast<String, dynamic>();
     deltas.add((next['ts'] as int) - (current['ts'] as int));
   }
   print(deltas);
diff --git a/tool/json_to_map.dart b/tool/json_to_map.dart
index dffb322..d3b1341 100644
--- a/tool/json_to_map.dart
+++ b/tool/json_to_map.dart
@@ -30,8 +30,9 @@
   }
 
   final jsonFileName = jsonFilePath.split('/').last;
-  final fileNameWithoutExtension = (jsonFileName.split('.')
-    ..removeLast()).join('.');
+  final fileNameWithoutExtension = (jsonFileName.split(
+    '.',
+  )..removeLast()).join('.');
   final jsonFileDirectoryPath = Uri.parse(
     (jsonFilePath.split('/')..removeLast()).join('/'),
   );
@@ -45,10 +46,9 @@
   // String interpolation.
   jsonFormattedString = jsonFormattedString.replaceAll('\$', '\\\$');
 
-  final dartFile =
-      File('$jsonFileDirectoryPath/$fileNameWithoutExtension.dart')
-        ..createSync()
-        ..writeAsStringSync('''
+  final dartFile = File('$jsonFileDirectoryPath/$fileNameWithoutExtension.dart')
+    ..createSync()
+    ..writeAsStringSync('''
 // Copyright 2023 The Flutter Authors
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file or at https://developers.google.com/open-source/licenses/bsd.