feat(dart/transform): Dedup getters, setters, & methods
Dedup the getters, setters, and methods generated by the transformer when compiling a template. Run `dartformat` over the transform code.
This commit is contained in:
@ -56,6 +56,14 @@ void allTests() {
|
||||
_formatThenExpectEquals(output, expected);
|
||||
});
|
||||
|
||||
it('should not generated duplicate getters/setters', () async {
|
||||
var inputPath = 'template_compiler/duplicate_files/hello.ng_deps.dart';
|
||||
var expected = readFile(
|
||||
'template_compiler/duplicate_files/expected/hello.ng_deps.dart');
|
||||
var output = await processTemplates(reader, new AssetId('a', inputPath));
|
||||
_formatThenExpectEquals(output, expected);
|
||||
});
|
||||
|
||||
describe('DirectiveMetadataReader', () {
|
||||
Future<DirectiveMetadata> readMetadata(inputPath) async {
|
||||
var ngDeps = await parser.parse(new AssetId('a', inputPath));
|
||||
|
Reference in New Issue
Block a user