(async, normalizer: DirectiveNormalizer) => {
   normalizer.normalizeTemplate(dirType, new CompileTemplateMetadata({
                                  encapsulation: null,
                                  template: '<style>@import test.css</style>',
                                  templateUrl: null,
                                  styles: [],
                                  styleUrls: []
                                }))
       .then((template: CompileTemplateMetadata) => {
         expect(template.styleUrls).toEqual(['package:some/module/test.css']);
         async.done();
       });
 }));
 (async, normalizer: DirectiveNormalizer) => {
   normalizer.normalizeTemplate(dirType, new CompileTemplateMetadata({
                                  encapsulation: null,
                                  template: '',
                                  templateUrl: null,
                                  styles: [],
                                  styleUrls: ['test.css']
                                }))
       .then((template: CompileTemplateMetadata) => {
         expect(template.encapsulation).toEqual(ViewEncapsulation.Emulated);
         async.done();
       });
 }));
 (async, normalizer: DirectiveNormalizer) => {
   normalizer.normalizeTemplate(dirType, new CompileTemplateMetadata({
                                  encapsulation: null,
                                  template: 'a',
                                  templateUrl: null,
                                  styles: [],
                                  styleUrls: ['test.css']
                                }))
       .then((template: CompileTemplateMetadata) => {
         expect(template.template).toEqual('a');
         expect(template.templateUrl).toEqual('package:some/module/a.js');
         async.done();
       });
 }));
 (async, config: CompilerConfig, normalizer: DirectiveNormalizer) => {
   config.defaultEncapsulation = ViewEncapsulation.None;
   normalizer.normalizeTemplate(dirType, new CompileTemplateMetadata({
                                  encapsulation: null,
                                  template: '',
                                  templateUrl: null,
                                  styles: [],
                                  styleUrls: ['test.css']
                                }))
       .then((template: CompileTemplateMetadata) => {
         expect(template.encapsulation).toEqual(ViewEncapsulation.None);
         async.done();
       });
 }));
 (async, normalizer: DirectiveNormalizer, xhr: MockXHR) => {
   xhr.expect('package:some/module/tpl/sometplurl.html', '');
   normalizer.normalizeTemplate(dirType, new CompileTemplateMetadata({
                                  encapsulation: null,
                                  template: null,
                                  templateUrl: 'tpl/sometplurl.html',
                                  styles: [],
                                  styleUrls: ['test.css']
                                }))
       .then((template: CompileTemplateMetadata) => {
         expect(template.styleUrls).toEqual(['package:some/module/test.css']);
         async.done();
       });
   xhr.flush();
 }));
 expect(() => normalizer.normalizeTemplate({
   componentType: SomeComp,
   moduleUrl: SOME_MODULE_URL,
 })).toThrowError(SyntaxError, 'No template specified for component SomeComp');
 () => normalizer.normalizeTemplate(
     dirType,
     new CompileTemplateMetadata({encapsulation: null, styles: [], styleUrls: []})))