Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Side by Side Diff: test/message_generator_test.dart

Issue 1192943003: changes for 0.3.9 (Closed) Base URL: https://github.com/dart-lang/dart-protoc-plugin.git@master
Patch Set: made mixins more general Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 #!/usr/bin/env dart 1 #!/usr/bin/env dart
2 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 2 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
3 // for details. All rights reserved. Use of this source code is governed by a 3 // for details. All rights reserved. Use of this source code is governed by a
4 // BSD-style license that can be found in the LICENSE file. 4 // BSD-style license that can be found in the LICENSE file.
5 5
6 library message_generator_test; 6 library message_generator_test;
7 7
8 import 'package:protoc_plugin/src/descriptor.pb.dart'; 8 import 'package:protoc_plugin/src/descriptor.pb.dart';
9 import 'package:protoc_plugin/src/plugin.pb.dart'; 9 import 'package:protoc_plugin/src/plugin.pb.dart';
10 import 'package:protoc_plugin/protoc.dart'; 10 import 'package:protoc_plugin/protoc.dart';
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 ..defaultValue = r'$' 105 ..defaultValue = r'$'
106 ]) 106 ])
107 ..enumType.add(ed); 107 ..enumType.add(ed);
108 MemoryWriter buffer = new MemoryWriter(); 108 MemoryWriter buffer = new MemoryWriter();
109 IndentingWriter writer = new IndentingWriter(' ', buffer); 109 IndentingWriter writer = new IndentingWriter(' ', buffer);
110 var options = parseGenerationOptions( 110 var options = parseGenerationOptions(
111 new CodeGeneratorRequest(), new CodeGeneratorResponse()); 111 new CodeGeneratorRequest(), new CodeGeneratorResponse());
112 var context = new GenerationContext(options, 112 var context = new GenerationContext(options,
113 new DefaultOutputConfiguration()); 113 new DefaultOutputConfiguration());
114 FileGenerator fg = new FileGenerator(fd, null, context); 114 FileGenerator fg = new FileGenerator(fd, null, context);
115 MessageGenerator mg = new MessageGenerator(md, fg, context, false); 115 MessageGenerator mg = new MessageGenerator(md, fg, context, null);
116 mg.initializeFields(); 116 mg.initializeFields();
117 mg.generate(writer); 117 mg.generate(writer);
118 expect(buffer.toString(), expected); 118 expect(buffer.toString(), expected);
119 }); 119 });
120 } 120 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698