diff options
| author | Misko Hevery | 2010-04-20 18:14:13 -0700 |
|---|---|---|
| committer | Misko Hevery | 2010-04-20 18:14:13 -0700 |
| commit | 22d93e0a3bc2a6dc0f64c63c68bc8f8489ea9068 (patch) | |
| tree | 5f65b04ac9fb5a69d87ac40434a14367e6c1d4fc /test/BinderTest.js | |
| parent | 259c2bba4bf1fc4f0d4cf5bcda4ffef0fb5a615a (diff) | |
| download | angular.js-22d93e0a3bc2a6dc0f64c63c68bc8f8489ea9068.tar.bz2 | |
fixes to enable ie
Diffstat (limited to 'test/BinderTest.js')
| -rw-r--r-- | test/BinderTest.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/BinderTest.js b/test/BinderTest.js index 50e1683a..31b2698d 100644 --- a/test/BinderTest.js +++ b/test/BinderTest.js @@ -151,7 +151,7 @@ BinderTest.prototype.testInputTypeButtonActionExecutesInScope = function(){ c.scope.$set("person.save", function(){ savedCalled = true; }); - c.node.click(); + c.node.trigger('click'); assertTrue(savedCalled); }; @@ -162,7 +162,7 @@ BinderTest.prototype.testInputTypeButtonActionExecutesInScope2 = function(){ log += 'click;'; }); expect(log).toEqual(''); - c.node.click(); + c.node.trigger('click'); expect(log).toEqual('click;'); }; @@ -172,7 +172,7 @@ BinderTest.prototype.testButtonElementActionExecutesInScope = function(){ c.scope.$set("person.save", function(){ savedCalled = true; }); - c.node.click(); + c.node.trigger('click'); assertTrue(savedCalled); }; @@ -435,13 +435,13 @@ BinderTest.prototype.testActionOnAHrefThrowsError = function(){ throw {a:'abc', b:2}; }; var input = c.node; - input.click(); + input.trigger('click'); assertEquals({a:"abc", b:2}, fromJson(input.attr('ng-exception'))); assertTrue("should have an error class", input.hasClass('ng-exception')); // TODO: I think that exception should never get cleared so this portion of test makes no sense //c.scope.action = noop; - //input.click(); + //input.trigger('click'); //dump(input.attr('ng-error')); //assertFalse('error class should be cleared', input.hasClass('ng-exception')); }; @@ -574,10 +574,10 @@ BinderTest.prototype.testItShouldDisplayErrorWhenActionIsSyntacticlyIncorect = f var first = jqLite(c.node[0].childNodes[0]); var second = jqLite(c.node[0].childNodes[1]); - first.click(); + first.trigger('click'); assertEquals("ABC", c.scope.greeting); - second.click(); + second.trigger('click'); assertTrue(second.hasClass("ng-exception")); }; |
