anchor.diff:      expect(state.needsRerun, true);
     }
   
  -  void test_applyHintAction() async {
  -    final path = convertPath('/home/tests/bin/test.dart');
  -    final file = getFile(path);
  -    final content = r'''
  -int x;
  -int y = x;
  -''';
  -    file.writeAsStringSync(content);
  -    final migratedContent = '''
  -int? x;
  -int? y = x;
  -''';
  -    final unitInfo = await buildInfoForSingleTestFile(content,
  -        migratedContent: migratedContent);
  -    site.unitInfoMap[path] = unitInfo;
  -    await site.performHintAction(
  -        unitInfo.regions[1].traces[0].entries[0].hintActions[0]);
  -    await site.performHintAction(
  -        unitInfo.regions[1].traces[0].entries[2].hintActions[0]);
  -    expect(file.readAsStringSync(), '''
  -int/*?*/ x;
  -int/*?*/ y = x;
  -''');
  -    expect(unitInfo.content, '''
  -int/*?*/? x;
  -int/*?*/? y = x;
  -''');
  -    assertRegion(
  -        region: unitInfo.regions[0], offset: unitInfo.content.indexOf('? x'));
  -    assertRegion(
  -        region: unitInfo.regions[1], offset: unitInfo.content.indexOf('? y'));
  -    final targets = List<NavigationTarget>.from(unitInfo.targets);
  -    assertInTargets(
  -        targets: targets,
  -        offset: unitInfo.content.indexOf('x'),
  -        offsetMapper: unitInfo.offsetMapper);
  -    assertInTargets(
  -        targets: targets,
  -        offset: unitInfo.content.indexOf('y'),
  -        offsetMapper: unitInfo.offsetMapper);
  -    var trace = unitInfo.regions[1].traces[0];
  -    assertTraceEntry(unitInfo, trace.entries[0], null,
  -        unitInfo.content.indexOf('int/*?*/? y'), contains('y (test.dart:2:1)'));
  -    assertTraceEntry(unitInfo, trace.entries[1], 'y',
  -        unitInfo.content.indexOf('= x;') + '= '.length, contains('data flow'));
  -    expect(state.hasBeenApplied, false);
  -    expect(state.needsRerun, true);
  -  }
  -
     void test_applyHintAction_removeHint() async {
       final path = convertPath('/home/tests/bin/test.dart');
       final file = getFile(path);
  
positive.code: // for details. All rights reserved. Use of this source code is governed by a
  // BSD-style license that can be found in the LICENSE file.
  
  import 'package:analysis_server/src/edit/fix/dartfix_listener.dart';
  import 'package:analyzer/file_system/memory_file_system.dart';
  import 'package:analyzer/src/test_utilities/resource_provider_mixin.dart';
  import 'package:analyzer_plugin/protocol/protocol_common.dart'
      hide NavigationTarget;
  import 'package:nnbd_migration/nnbd_migration.dart';
  import 'package:nnbd_migration/src/front_end/migration_info.dart';
  import 'package:nnbd_migration/src/front_end/migration_state.dart';
  import 'package:nnbd_migration/src/front_end/offset_mapper.dart';
  
negative.code:     });
    }
  
    void test_applyHintAction() async {
      final path = convertPath('/home/tests/bin/test.dart');
      final file = getFile(path);
      final content = r'''
  int x;
  int y = x;
  ''';
      file.writeAsStringSync(content);
      final migratedContent = '''
  int? x;
  int? y = x;
  ''';
      final unitInfo = await buildInfoForSingleTestFile(content,
          migratedContent: migratedContent);
      site.unitInfoMap[path] = unitInfo;
      await site.performHintAction(
          unitInfo.regions[1].traces[0].entries[0].hintActions[0]);
      await site.performHintAction(
          unitInfo.regions[1].traces[0].entries[2].hintActions[0]);
      expect(file.readAsStringSync(), '''
  int/*?*/ x;
  int/*?*/ y = x;
  ''');
      expect(unitInfo.content, '''
  int/*?*/? x;
  int/*?*/? y = x;
  ''');
      assertRegion(
          region: unitInfo.regions[0], offset: unitInfo.content.indexOf('? x'));
      assertRegion(
          region: unitInfo.regions[1], offset: unitInfo.content.indexOf('? y'));
      final targets = List<NavigationTarget>.from(unitInfo.targets);
      assertInTargets(
          targets: targets,
          offset: unitInfo.content.indexOf('x'),
          offsetMapper: unitInfo.offsetMapper);
      assertInTargets(
          targets: targets,
          offset: unitInfo.content.indexOf('y'),
          offsetMapper: unitInfo.offsetMapper);
      var trace = unitInfo.regions[1].traces[0];
      assertTraceEntry(unitInfo, trace.entries[0], null,
          unitInfo.content.indexOf('int/*?*/? y'), contains('y (test.dart:2:1)'));
      assertTraceEntry(unitInfo, trace.entries[1], 'y',
          unitInfo.content.indexOf('= x;') + '= '.length, contains('data flow'));
      expect(state.hasBeenApplied, false);
      expect(state.needsRerun, true);
    }
  
    void test_performEdit_multiple() async {
      final path = convertPath('/test.dart');
      final file = getFile(path);
  