Changeset 2479:6883db18a27e for tests/functional/spec/page_tabs.js
- Timestamp:
- 10/22/13 14:22:06 (12 years ago)
- Branch:
- 2.6
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tests/functional/spec/page_tabs.js
r2471 r2479 153 153 expect($('#part-user-favorites')).not.toBeVisible(); 154 154 }); 155 156 /* ticket 17 94 */157 /*155 156 /* ticket 1723 and 1794 157 * 158 158 * The problem occurs when cliking an anchor in the page 159 159 */ 160 it("Must not change opened tab when hash does not referto an existing div content", function() {160 it("Must try to find tab to open in page when hash refer ton an anchor and not to an existing div content", function() { 161 161 loadFixtures('tabs.html'); 162 162 loadStyleFixtures('default.css'); 163 164 var anchor_name = 'anchor-in-favorites'; 165 $('<div id="anchor-in-favorites"></div>').appendTo($('#user-favorites')); 163 166 164 167 $.pageTabs('user-profile'); … … 167 170 expect($('#part-user-favorites')).not.toBeVisible(); 168 171 169 spyOn(jQuery.pageTabs, 'getLocationHash').andReturn( 'dummy');172 spyOn(jQuery.pageTabs, 'getLocationHash').andReturn(anchor_name); 170 173 jQuery.event.trigger('hashchange'); 171 174 expect($('#part-user-options')).not.toBeVisible(); 172 expect($('#part-user-profile')). toBeVisible();173 expect($('#part-user-favorites')). not.toBeVisible();175 expect($('#part-user-profile')).not.toBeVisible(); 176 expect($('#part-user-favorites')).toBeVisible(); 174 177 }); 175 178 176 /* ticket 1723 */ 177 it("Must open first tab when hash does not refer to an existing div content and no tab is opened", function() { 179 it("Must open first tab when hash does not refer to an existing div content", function() { 178 180 loadFixtures('tabs.html'); 179 181 loadStyleFixtures('default.css');
Note: See TracChangeset
for help on using the changeset viewer.