title: How to create new event for unit testing in Angular 2?
body: <p>Hi I am writing unit test case for my angular code. I am trying to update textbox in gridview. Below is my gridview code.</p>
  
  <pre><code>&lt;input *ngIf="editing[rowIndex + '-scopevalue']" class="inline-editor" autofocus (blur)="updateValue($event, 'scopevalue', value, rowIndex)" type="text" [value]="value" /&gt;
  </code></pre>
  
  <p>Below function performs update.</p>
  
  <pre><code> updateValue(event, cell, cellValue, rowIndex) {
          this.editing[rowIndex + '-' + cell] = false;
          this.rows[rowIndex][cell] = event.target.value;
          this.rowsCache[rowIndex][cell] = event.target.value;
          this.scopeEdit = this.rows[rowIndex];
          this.updateScope();
      }
  </code></pre>
  
  <p>Below unit test case I am writing to check above code.</p>
  
  <pre><code> it('update scope name value', () =&gt; {
          var row = component.rows[0];
          let cell = 'scopevalue';
          let cellValue = row.scopevalue;
          let rowIndex = 0;
          component.updateValue('/bmw', cell, cellValue, rowIndex);
      });
  </code></pre>
  
  <p>In the above method, first parameter supposed to be event. Can someone help me how to create event? Any help would be appreciated. Thank you</p>