aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tests/unit/menu/core.js4
-rw-r--r--tests/unit/menu/events.js10
2 files changed, 7 insertions, 7 deletions
diff --git a/tests/unit/menu/core.js b/tests/unit/menu/core.js
index 08644c31f..dc853be3c 100644
--- a/tests/unit/menu/core.js
+++ b/tests/unit/menu/core.js
@@ -47,8 +47,8 @@ asyncTest( "#9044: Autofocus issue with dialog opened from menu widget", functio
$( "<input>", { id: "test9044" } ).appendTo( "body" );
- $( "#testID1" ).bind( "click", function() {
- $( "#test9044" ).focus();
+ $( "#testID1" ).on( "click", function() {
+ $( "#test9044" ).trigger( "focus" );
});
testHelper.click( element, "3" );
diff --git a/tests/unit/menu/events.js b/tests/unit/menu/events.js
index 5cac3e737..88a1f288c 100644
--- a/tests/unit/menu/events.js
+++ b/tests/unit/menu/events.js
@@ -62,7 +62,7 @@ asyncTest( "handle blur", function() {
click( element, "1" );
setTimeout(function() {
- element.blur();
+ element.trigger( "blur" );
setTimeout(function() {
start();
}, 350 );
@@ -303,7 +303,7 @@ asyncTest( "handle keyboard navigation on menu without scroll and with submenus"
equal( logOutput(), "keydown,1,2", "Keydown DOWN" );
setTimeout( menukeyboard1 );
});
- element.focus();
+ element.trigger( "focus" );
function menukeyboard1() {
log( "keydown", true );
@@ -498,7 +498,7 @@ asyncTest( "handle keyboard navigation on menu with scroll and with submenus", f
equal( logOutput(), "keydown,1,2", "Keydown DOWN" );
setTimeout( menukeyboard1 );
});
- element.focus();
+ element.trigger( "focus" );
function menukeyboard1() {
log( "keydown", true );
@@ -593,7 +593,7 @@ asyncTest( "handle keyboard navigation and mouse click on menu with disabled ite
equal( logOutput(), "keydown,1", "Keydown focus but not select disabled item" );
setTimeout( menukeyboard1, 50 );
});
- element.focus();
+ element.trigger( "focus" );
function menukeyboard1() {
log( "keydown", true );
@@ -645,7 +645,7 @@ asyncTest( "handle keyboard navigation and mouse click on menu with dividers and
equal( logOutput(), "keydown,2,Ada", "Keydown skips initial group label" );
setTimeout( menukeyboard1, 50 );
});
- element.focus();
+ element.trigger( "focus" );
function menukeyboard1() {
log( "keydown", true );