aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit/event.js
diff options
context:
space:
mode:
authorRichard Gibson <richard.gibson@gmail.com>2013-04-04 19:26:08 -0400
committerRichard Gibson <richard.gibson@gmail.com>2013-04-04 19:26:08 -0400
commitf8b27f16ba748627fd8e56965047d6d1ebd90b4b (patch)
tree78603c4126906c805ae8fd7a910e00d9e214b77e /test/unit/event.js
parent58b8535d5d00a09660d87a6a8e1c86a478e416fc (diff)
downloadjquery-f8b27f16ba748627fd8e56965047d6d1ebd90b4b.tar.gz
jquery-f8b27f16ba748627fd8e56965047d6d1ebd90b4b.zip
Ref 65a66489: oldIE handholding for native event tests
Diffstat (limited to 'test/unit/event.js')
-rw-r--r--test/unit/event.js9
1 files changed, 8 insertions, 1 deletions
diff --git a/test/unit/event.js b/test/unit/event.js
index 070f75a0b..d38dbb8d1 100644
--- a/test/unit/event.js
+++ b/test/unit/event.js
@@ -1490,7 +1490,7 @@ test("jQuery.Event( type, props )", function() {
test("jQuery.Event properties", function(){
expect(12);
- var handler,
+ var handler, event,
$structure = jQuery("<div id='ancestor'><p id='delegate'><span id='target'>shiny</span></p></div>"),
$target = $structure.find("#target");
@@ -1517,12 +1517,19 @@ test("jQuery.Event properties", function(){
handler = function( e ) {
strictEqual( e.isTrigger, undefined, "native event at " + this.id );
+ event = e;
};
$target.one( "click", handler );
$target[0].onclick = function( e ) {
strictEqual( e.isTrigger, undefined, "native event at target (native handler)" );
+ $target[0].onclick = null;
};
fireNative( $target[0], "click" );
+
+ // Make sure that even oldIE executes the inline handler
+ if ( $target[0].onclick ) {
+ $target[0].onclick( event );
+ }
});
test(".delegate()/.undelegate()", function() {