title: Angular2 - Testing a Component with templateUrl resulting in "Unhandled Promise rejection"
body: <p>I'm currently writing a simple test to test an Angular 2 component whose template is referenced with a templateUrl. I am currently using webpack to perform the tasks required, including testing. I was following the <a href="https://angular.io/docs/ts/latest/guide/webpack.html#!#test-configuration" rel="nofollow">webpack guide on the angular site</a>  as well as the AngularClass' <a href="https://github.com/AngularClass/angular2-webpack-starter" rel="nofollow">angular2-webpack-starter repo</a>. </p>
  
  <p>However, when the test tries to create a component fixture, using</p>
  
  <pre><code>testBed.createComponent(AppComponent);
  </code></pre>
  
  <p>I am getting the following error: </p>
  
  <p>"'Unhandled Promise rejection:', 'Failed to load app.component.html', '; Zone:', 'ProxyZone', '; Task:', 'Promise.then', '; Value:', 'Failed to load app.component.html',"</p>
  
  <p>thus obviously resulting in a failing test.</p>
  
  <p>In my app.component.ts i'm refering the template via templateUrl like so</p>
  
  <pre><code>@Component({
      selector: 'my-app',
      templateUrl: './app.component.html',
      styleUrls: [ './app.component.css' ]
  })
  export class AppComponent {
      title = "Tour of Heroes";
  }
  </code></pre>
  
  <p>I Have looked around but haven't found a solution for this error. Anybody aware of this issue please? All the examples which I have encountered so far (for example like the ones in this repo <a href="https://github.com/rangle/angular2-redux-example" rel="nofollow">https://github.com/rangle/angular2-redux-example</a>) all include inline html.</p>
  
  <p>Here's a link to my repo in case you would like to see the webpack / karma config files.  <a href="https://github.com/jeanpaulattard/tourofheroes" rel="nofollow">https://github.com/jeanpaulattard/tourofheroes</a></p>
  
  <p>Edit: Updated link to the master branch of my repo.</p>