anchor.diff:      verifyCreatedCollection();
     }
   }
  -
  -/// Wraps the given [_ElementVisitorFunction] into an instance of
  -/// [engine.GeneralizingElementVisitor].
  -class _ElementVisitorFunctionWrapper extends GeneralizingElementVisitor<void> {
  -  final _ElementVisitorFunction function;
  -  _ElementVisitorFunctionWrapper(this.function);
  -
  -  @override
  -  void visitElement(Element element) {
  -    function(element);
  -    super.visitElement(element);
  -  }
  -}
  
positive.code: 
  import 'src/utilities/mock_packages.dart';
  
  /// Finds an [Element] with the given [name].
  Element? findChildElement(Element root, String name, [ElementKind? kind]) {
    Element? result;
    root.accept(_ElementVisitorFunctionWrapper((Element element) {
      if (element.name != name) {
        return;
      }
      if (kind != null && element.kind != kind) {
        return;
      }
      result = element;
    }));
    return result;
  }
  
  /// A function to be called for every [Element].
  typedef _ElementVisitorFunction = void Function(Element element);
  
  class AbstractContextTest with ResourceProviderMixin {
    static bool _lintRulesAreRegistered = false;
  
  
negative.code: import 'package:analyzer/dart/analysis/analysis_context.dart';
  import 'package:analyzer/dart/analysis/results.dart';
  import 'package:analyzer/dart/analysis/session.dart';
  import 'package:analyzer/file_system/file_system.dart';
  import 'package:analyzer/src/dart/analysis/analysis_context_collection.dart';
  import 'package:analyzer/src/dart/analysis/byte_store.dart';
  