Angular2 testing form: submit method not called
<p>Having this component</p>

<pre><code>import {Component} from 'angular2/core';
import { FORM_DIRECTIVES } from 'angular2/common';

@Component({
    selector: 'something',
    templateUrl: 'something.html',
    providers: [],
    directives: [FORM_DIRECTIVES],
    pipes: []
})
export class Something {

    constructor() { }

    save(data) {
        alert(data);
    }
}
</code></pre>

<p>with this template (something.html)</p>

<pre><code>&lt;form #myForm="ngForm" (ngSubmit)="save(myForm.value)"&gt;
    &lt;label for="title"&gt;Title&lt;/label&gt;
    &lt;input id="title" type="text" ngControl="title" /&gt;

    &lt;label for="primaryImage"&gt;Primary Image&lt;/label&gt;
    &lt;input id="primaryImage" type="text" ngControl="primaryImage" /&gt;

    &lt;button type="submit"&gt;Save&lt;/button&gt;
&lt;/form&gt;
</code></pre>

<p>and this test</p>

<pre><code>it('should call save method after clicking a Save button', injectAsync([TestComponentBuilder], (tcb: TestComponentBuilder) =&gt; {
    return tcb.createAsync(Something).then((fixture) =&gt; {
        spyOn(fixture.componentInstance, 'save');
        fixture.detectChanges();
        const compiled = fixture.nativeElement;
        compiled.querySelector('#title').value = 'testTitle';
        compiled.querySelector('#primaryImage').value = 'tabc.png';                   
        compiled.querySelector('button').click();
        expect(fixture.componentInstance.save).toHaveBeenCalledWith({
            title: 'testTitle',
            primaryImage: 'abc.png'
        });
    });
}));
</code></pre>

<p>The test fails, the save method hasn't been called on the spy.
However, when I manually try it in browser, if works, alert is shown.
The test fails too when instead of button.click I do form.submit.</p>

<p>When I use <code>(click)="save(myForm.value)"</code> on the button instead of <code>ngSubmit</code> on the form, test still fails, but the reason is different. Save method on the spy has been called in this case, but the data passed to it is <code>{}</code>.</p>

<p>Can anyone tell me what am I missing here?</p>