anchor.diff:  
   const _violations = 'violations';
   
  -Code _createValidator(DescriptorProto descriptor, String fullName) {
  -    var violation = refer('ConstraintViolation', 'package:spine_base/spine/validate/validation_error.pb.dart');
  +Code _createValidator(DescriptorProto descriptor, String fullName, Allocator allocator, String fileName) {
  +    var violation = refer('ConstraintViolation', _validationErrorImport);
       var validations = <Code>[];
       for (var field in descriptor.field) {
  -        var validator = _createFieldValidator(field, fullName, descriptor.name);
  +        var validator = _createFieldValidator(field, fullName, descriptor.name, allocator, fileName);
           if (validator != null) {
               validations.add(validator);
           }
  
positive.code:         var fieldPath = 'fieldPath';
  
          b..name = '_violation'
           ..returns = refer('ConstraintViolation', 'package:spine_base/spine/validate/validation_error.pb.dart')
           ..requiredParameters.add(Parameter((b) => b..type = refer('String')..name = msgFormat))
           ..requiredParameters.add(Parameter((b) => b..type = refer('String')..name = typeName))
           ..requiredParameters.add(Parameter((b) => b..type = TypeReference((b) => b..symbol = 'List'..types.add(refer('String')))..name = fieldPath))
  
           ..body = Block.of([
               refer('ConstraintViolation', 'package:spine_base/spine/validate/validation_error.pb.dart').newInstance([]).assignVar(violation).statement,
               violationRef.property('msgFormat').assign(refer(msgFormat)).statement,
               violationRef.property('typeName').assign(refer(typeName)).statement,
               refer('FieldPath', 'package:spine_base/spine/base/field_path.pb.dart').newInstance([]).assignVar('path').statement,
  
negative.code: import 'package:dart_style/dart_style.dart';
  
  String generateClassTest(FileDescriptorSet descriptorSet) {
      var allocator = Allocator.simplePrefixing();
      var code = Library((b) =>
          b..body.add(_createValidatorMap(descriptorSet, allocator))
           ..body.add(_createViolationFactory())
      );
      var emitter = DartEmitter(allocator);
      var formatter = DartFormatter();
      return formatter.format(code.accept(emitter).toString());
  }
  
  const _msg = 'msg';
  const _validationErrorImport = 'package:spine_base/spine/validate/validation_error.pb.dart';
  
  Field _createValidatorMap(FileDescriptorSet descriptorSet, Allocator allocator) {
      var keyType = refer('String');
      var validationError = refer('ValidationError', _validationErrorImport);
      var valueType = FunctionType((b) => b
          ..requiredParameters.add(refer('GeneratedMessage', 'package:protobuf/protobuf.dart'))
          ..returnType = validationError);
      var validatorMap = Map<String, Expression>();
      for (var file in descriptorSet.file) {
          var fileName = file.name.substring(0, file.name.length - 'proto'.length) + 'pb.dart';
          for (var type in file.messageType) {
              var name = '${file.package}.${type.name}';
              var lambda = Method((b) => b
                  ..body = _createValidator(type, name, allocator, fileName)
                  ..requiredParameters.add(Parameter((b) => b.name = _msg)))
                  .closure;
              validatorMap[name] = lambda;
  