aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorMisko Hevery2010-04-19 17:02:46 -0700
committerMisko Hevery2010-04-19 17:02:46 -0700
commit259c2bba4bf1fc4f0d4cf5bcda4ffef0fb5a615a (patch)
tree6bff2acb37421eb70539001d5477fbbac77231e5 /test
parent47ec2187776658ad9ee2a9c71a28ddb860bec43a (diff)
downloadangular.js-259c2bba4bf1fc4f0d4cf5bcda4ffef0fb5a615a.tar.bz2
last failing ie test remaining
Diffstat (limited to 'test')
-rw-r--r--test/BinderTest.js12
-rw-r--r--test/testabilityPatch.js6
2 files changed, 7 insertions, 11 deletions
diff --git a/test/BinderTest.js b/test/BinderTest.js
index ec0c1cb4..50e1683a 100644
--- a/test/BinderTest.js
+++ b/test/BinderTest.js
@@ -16,7 +16,9 @@ BinderTest.prototype.setUp = function(){
};
BinderTest.prototype.tearDown = function(){
- if (this.element && this.element.dealoc) this.element.dealoc();
+ if (this.element && this.element.dealoc) {
+ this.element.dealoc();
+ }
};
@@ -100,8 +102,8 @@ BinderTest.prototype.testBindingSpaceConfusesIE = function() {
'<b><span ng-bind="a"></span><span>'+nbsp+'</span><span ng-bind="b"></span></b>',
this.compileToHtml("<b>{{a}} {{b}}</b>"));
assertEquals(
- '<span ng-bind="A"></span><span>'+nbsp+'x </span><span ng-bind="B"></span><span>'+nbsp+'(</span><span ng-bind="C"></span>',
- this.compileToHtml("{{A}} x {{B}} ({{C}})"));
+ '<b><span ng-bind="A"></span><span>'+nbsp+'x </span><span ng-bind="B"></span><span>'+nbsp+'(</span><span ng-bind="C"></span>)</b>',
+ this.compileToHtml("<b>{{A}} x {{B}} ({{C}})</b>"));
};
BinderTest.prototype.testBindingOfAttributes = function() {
@@ -586,13 +588,13 @@ BinderTest.prototype.testItShouldSelectTheCorrectRadioBox = function() {
var female = jqLite(c.node[0].childNodes[0]);
var male = jqLite(c.node[0].childNodes[1]);
- trigger(female, 'click');
+ female.trigger('click');
assertEquals("female", c.scope.sex);
assertEquals(true, female[0].checked);
assertEquals(false, male[0].checked);
assertEquals("female", female.val());
- trigger(male, 'click');
+ male.trigger('click');
assertEquals("male", c.scope.sex);
assertEquals(false, female[0].checked);
assertEquals(true, male[0].checked);
diff --git a/test/testabilityPatch.js b/test/testabilityPatch.js
index 21443fa5..17341575 100644
--- a/test/testabilityPatch.js
+++ b/test/testabilityPatch.js
@@ -27,12 +27,6 @@ extend(angular, {
});
-function trigger(element, type) {
- var evnt = document.createEvent('MouseEvent');
- evnt.initMouseEvent(type, true, true, window, 0, 0, 0, 0, 0, false, false, false, false, 0, null);
- (element[0] || element).dispatchEvent(evnt);
-}
-
function sortedHtml(element) {
var html = "";
foreach(element, function toString(node) {