title: Passing a mock DOM event to component method in Angular for unit testing
body: <p>I am trying to test a method in one of my components as follows:</p>
  
  <pre><code>toggle(event: Event): void {
      event.stopPropagation();
      this.isCollapsed = !this.isCollapsed;
  }
  </code></pre>
  
  <p>I cannot find a way to pass the event object to the method in the unit test case for example:</p>
  
  <pre><code>test('it should call stop propagation when toggled', () =&gt; {
      testHostComponent.toggleLineBreakDown(mockEventGoesHere, 0);
  });
  </code></pre>