mirror of
https://github.com/Hopiu/jquery-mobile.git
synced 2026-03-16 22:10:25 +00:00
test that title is restored on link transition to first page
This commit is contained in:
parent
c997b4cc20
commit
949dd4c6c8
2 changed files with 28 additions and 3 deletions
|
|
@ -520,6 +520,30 @@
|
|||
]);
|
||||
});
|
||||
|
||||
asyncTest( "Page title updates properly when clicking a link back to first page", function(){
|
||||
var title = document.title;
|
||||
|
||||
$.testHelper.pageSequence([
|
||||
function(){
|
||||
$.testHelper.openPage("#ajax-title-page");
|
||||
},
|
||||
|
||||
function(){
|
||||
$("#titletest1").click();
|
||||
},
|
||||
|
||||
function(){
|
||||
same(document.title, "Title Tag");
|
||||
$.mobile.activePage.find("#title-check-link").click();
|
||||
},
|
||||
|
||||
function(){
|
||||
same(document.title, title);
|
||||
start();
|
||||
}
|
||||
]);
|
||||
});
|
||||
|
||||
asyncTest( "Page title updates properly from title tag when loading an external page", function(){
|
||||
$.testHelper.pageSequence([
|
||||
function(){
|
||||
|
|
|
|||
|
|
@ -6,7 +6,8 @@
|
|||
</head>
|
||||
<body>
|
||||
|
||||
<div data-nstest-role="page"></div>
|
||||
|
||||
<div data-nstest-role="page">
|
||||
<a href="./" id="title-check-link">back to the parent page</a>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
|
|
|||
Loading…
Reference in a new issue