Menu tests: Added test for widget() method.

This commit is contained in:
Scott González 2012-08-26 20:17:36 -04:00
parent 355a1a6f0a
commit 2e491e0bb7

View File

@ -60,6 +60,14 @@ test( "refresh", function() {
equal( element.find( ".ui-menu-item" ).length, 5, "Incorrect number of menu items" );
});
test( "widget", function() {
expect( 2 );
var element = $( "#menu1" ).menu(),
widgetElement = element.menu( "widget" );
equal( widgetElement.length, 1, "one element" );
strictEqual( widgetElement[ 0 ], element[ 0 ], "same element" );
});
// TODO: test focus method
// TODO: test blur method