mirror of
https://github.com/Hopiu/jquery-mobile.git
synced 2026-05-17 02:51:07 +00:00
fixed order dependent tests in listview
This commit is contained in:
parent
45183c186c
commit
3316e559b3
1 changed files with 25 additions and 16 deletions
|
|
@ -143,7 +143,10 @@
|
|||
asyncTest( "change the page to the split view page 1 when the first link is clicked", function() {
|
||||
$.testHelper.openPage("#split-list-test");
|
||||
|
||||
$('.ui-page-active [role="option"]:eq(0)').click();
|
||||
setTimeout(function(){
|
||||
$('.ui-page-active [role="option"]:eq(0)').click();
|
||||
}, 500);
|
||||
|
||||
setTimeout(function() {
|
||||
ok($('#split-list-link1').hasClass('ui-page-active'));
|
||||
start();
|
||||
|
|
@ -152,30 +155,36 @@
|
|||
|
||||
asyncTest( "Slide back to the parent list view when the back button is clicked", function() {
|
||||
$.testHelper.openPage("#split-list-test");
|
||||
|
||||
$('.ui-page-active a:contains("Back")').click();
|
||||
setTimeout(function() {
|
||||
ok($('#split-list-test').hasClass('ui-page-active'));
|
||||
start();
|
||||
}, 1000);
|
||||
|
||||
$.testHelper.sequence([
|
||||
function(){
|
||||
$('.ui-page-active [role="option"]:eq(0)').click();
|
||||
},
|
||||
|
||||
function(){
|
||||
$('.ui-page-active a:contains("Back")').click();
|
||||
},
|
||||
|
||||
function() {
|
||||
ok($('#split-list-test').hasClass('ui-page-active'));
|
||||
start();
|
||||
}
|
||||
], 1000);
|
||||
});
|
||||
|
||||
asyncTest( "Clicking on the icon (the second link) should take the user to other a href of this LI", function() {
|
||||
$('.ui-page-active .ui-li-link-alt:eq(0)').click();
|
||||
$.testHelper.openPage("#split-list-test");
|
||||
|
||||
setTimeout(function(){
|
||||
$('.ui-page-active .ui-li-link-alt:eq(0)').click();
|
||||
}, 500);
|
||||
|
||||
setTimeout(function() {
|
||||
ok($('#split-list-link2').hasClass('ui-page-active'));
|
||||
start();
|
||||
}, 1000);
|
||||
});
|
||||
|
||||
asyncTest( "Slide back to the parent list view when the back button is clicked", function() {
|
||||
$('.ui-page-active a:contains("Back")').click();
|
||||
setTimeout(function() {
|
||||
ok($('#split-list-test').hasClass('ui-page-active'));
|
||||
start();
|
||||
}, 1000);
|
||||
});
|
||||
|
||||
module( "List Dividers" );
|
||||
|
||||
asyncTest( "Makes the list divider page the active page and enhances it correctly.", function() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue