]> source.dussan.org Git - jquery-ui.git/commitdiff
Tabs: unit test to verify that number of panels is equal to number of tabs.
authordominiquevincent <dominique.vincent@toitl.com>
Sun, 9 May 2010 18:25:12 +0000 (02:25 +0800)
committerRichard D. Worth <rdworth@gmail.com>
Mon, 10 May 2010 08:36:13 +0000 (16:36 +0800)
Ticket #5069 - tabs: ui.tabs.add creates two tab panels when using a full URL

Signed-off-by: dominiquevincent <dominique.vincent@toitl.com>
tests/unit/tabs/tabs_tickets.js

index 9874a1192f52a66610065bdabf3c10f357be8de5..4d51e905d6c027630b0361dfb92e2727254ed956 100644 (file)
@@ -59,5 +59,16 @@ test('#4033 - IE expands hash to full url and misinterprets tab as ajax', functi
        
 });
 
+test('#5069 - ui.tabs.add creates two tab panels when using a full URL', function() {
+       // http://dev.jqueryui.com/ticket/5069
+       expect(2);
+       
+       el = $('#tabs2').tabs();
+       equals(el.children('div').length, el.find('> ul > li').length, 'After creation, number of panels should be equal to number of tabs');
+       el.tabs('add', '/ajax_html_echo', 'Test');
+       equals(el.children('div').length, el.find('> ul > li').length, 'After add, number of panels should be equal to number of tabs');
+       
+});
+
 
 })(jQuery);