fix(view): fixed hydrator to pass the right element index when attaching an event listener

This commit is contained in:
vsavkin
2015-04-17 16:08:59 -07:00
parent 00e2d70f05
commit 4943c0f887
7 changed files with 121 additions and 37 deletions

View File

@ -80,6 +80,13 @@ export function main() {
expect(spyObj.spy("someFunc")).toHaveBeenCalledWith(1,2);
});
it("should support stubs", () => {
var s = SpyObject.stub({"a":1}, {"b":2});
expect(s.a()).toEqual(1);
expect(s.b()).toEqual(2);
});
it('should create spys for all methods', () => {
expect(() => spyObj.someFunc()).not.toThrow();
});