]> source.dussan.org Git - jquery-ui.git/commitdiff
Datepicker Tests: use simulated events for focus and blur.
authorMike Sherov <mike.sherov@gmail.com>
Sun, 7 Apr 2013 19:15:04 +0000 (15:15 -0400)
committerMike Sherov <mike.sherov@gmail.com>
Sun, 7 Apr 2013 19:15:04 +0000 (15:15 -0400)
tests/unit/datepicker/datepicker_options.js
tests/unit/datepicker/datepicker_test_helpers.js

index 64bbc882936ca1bf28440d897b652ceda364af75..93ffc8136683a6abf17d66cfa244be647a3fe8c4 100644 (file)
@@ -114,7 +114,7 @@ asyncTest( "invocation", function() {
 
                                step2();
                        });
-               })[ 0 ].focus();
+               }).simulate( "focus" );
        }
 
        function step2() {
index 504bcc76731ff0f91a84683b0018a683e333ef93..884735def5807f9a0816fdb556701cc9fa057318 100644 (file)
@@ -22,8 +22,8 @@ TestHelpers.datepicker = {
                element.one( "blur", function(){
                        element.one( "focus", function(){
                                callback();
-                       })[ 0 ].focus();
-               })[ 0 ].blur();
+                       }).simulate( "focus" );
+               }).simulate( "blur" );
        },
        PROP_NAME: "datepicker"
 };
\ No newline at end of file