mirror of
https://github.com/DataTables/DataTables.git
synced 2024-12-01 13:24:10 +01:00
Update unit tests to take account of the change to the pagination elements now being A tags, rather than SPANs/DIVs. Good that the change broke the unit tests since it is backwards incompatible
This commit is contained in:
parent
bccc85ef9f
commit
7d2d62d519
@ -19,9 +19,9 @@ $(document).ready( function () {
|
||||
);
|
||||
|
||||
oTest.fnTest(
|
||||
"Two div elements are in the wrapper",
|
||||
"Two A elements are in the wrapper",
|
||||
null,
|
||||
function () { return $('#example_paginate div').length == 2; }
|
||||
function () { return $('#example_paginate a').length == 2; }
|
||||
);
|
||||
|
||||
oTest.fnTest(
|
||||
@ -75,10 +75,10 @@ $(document).ready( function () {
|
||||
oTest.fnTest(
|
||||
"Jump to last page",
|
||||
function () {
|
||||
nFirst = $('div.dataTables_paginate span.first');
|
||||
nPrevious = $('div.dataTables_paginate span.previous');
|
||||
nNext = $('div.dataTables_paginate span.next');
|
||||
nLast = $('div.dataTables_paginate span.last');
|
||||
nFirst = $('div.dataTables_paginate a.first');
|
||||
nPrevious = $('div.dataTables_paginate a.previous');
|
||||
nNext = $('div.dataTables_paginate a.next');
|
||||
nLast = $('div.dataTables_paginate a.last');
|
||||
nLast.click();
|
||||
},
|
||||
function () {
|
||||
|
@ -21,9 +21,9 @@ $(document).ready( function () {
|
||||
);
|
||||
|
||||
oTest.fnTest(
|
||||
"Two div elements are in the wrapper",
|
||||
"Two A elements are in the wrapper",
|
||||
null,
|
||||
function () { return $('#example_paginate div').length == 2; }
|
||||
function () { return $('#example_paginate a').length == 2; }
|
||||
);
|
||||
|
||||
oTest.fnTest(
|
||||
@ -78,10 +78,10 @@ $(document).ready( function () {
|
||||
oTest.fnTest(
|
||||
"Jump to last page",
|
||||
function () {
|
||||
nFirst = $('div.dataTables_paginate span.first');
|
||||
nPrevious = $('div.dataTables_paginate span.previous');
|
||||
nNext = $('div.dataTables_paginate span.next');
|
||||
nLast = $('div.dataTables_paginate span.last');
|
||||
nFirst = $('div.dataTables_paginate a.first');
|
||||
nPrevious = $('div.dataTables_paginate a.previous');
|
||||
nNext = $('div.dataTables_paginate a.next');
|
||||
nLast = $('div.dataTables_paginate a.last');
|
||||
nLast.click();
|
||||
},
|
||||
function () {
|
||||
|
@ -21,9 +21,9 @@ $(document).ready( function () {
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
"Two div elements are in the wrapper",
|
||||
"Two A elements are in the wrapper",
|
||||
null,
|
||||
function () { return $('#example_paginate div').length == 2; }
|
||||
function () { return $('#example_paginate a').length == 2; }
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
@ -87,10 +87,10 @@ $(document).ready( function () {
|
||||
oTest.fnWaitTest(
|
||||
"Jump to last page",
|
||||
function () {
|
||||
nFirst = $('div.dataTables_paginate span.first');
|
||||
nPrevious = $('div.dataTables_paginate span.previous');
|
||||
nNext = $('div.dataTables_paginate span.next');
|
||||
nLast = $('div.dataTables_paginate span.last');
|
||||
nFirst = $('div.dataTables_paginate a.first');
|
||||
nPrevious = $('div.dataTables_paginate a.previous');
|
||||
nNext = $('div.dataTables_paginate a.next');
|
||||
nLast = $('div.dataTables_paginate a.last');
|
||||
nLast.click();
|
||||
},
|
||||
function () {
|
||||
|
@ -22,9 +22,9 @@ $(document).ready( function () {
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
"Two div elements are in the wrapper",
|
||||
"Two A elements are in the wrapper",
|
||||
null,
|
||||
function () { return $('#example_paginate div').length == 2; }
|
||||
function () { return $('#example_paginate a').length == 2; }
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
@ -91,10 +91,10 @@ $(document).ready( function () {
|
||||
oTest.fnWaitTest(
|
||||
"Jump to last page",
|
||||
function () {
|
||||
nFirst = $('div.dataTables_paginate span.first');
|
||||
nPrevious = $('div.dataTables_paginate span.previous');
|
||||
nNext = $('div.dataTables_paginate span.next');
|
||||
nLast = $('div.dataTables_paginate span.last');
|
||||
nFirst = $('div.dataTables_paginate a.first');
|
||||
nPrevious = $('div.dataTables_paginate a.previous');
|
||||
nNext = $('div.dataTables_paginate a.next');
|
||||
nLast = $('div.dataTables_paginate a.last');
|
||||
nLast.click();
|
||||
},
|
||||
function () {
|
||||
|
@ -28,9 +28,9 @@ $(document).ready( function () {
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
"Two div elements are in the wrapper",
|
||||
"Two A elements are in the wrapper",
|
||||
null,
|
||||
function () { return $('#example_paginate div').length == 2; }
|
||||
function () { return $('#example_paginate a').length == 2; }
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
@ -101,10 +101,10 @@ $(document).ready( function () {
|
||||
oTest.fnWaitTest(
|
||||
"Jump to last page",
|
||||
function () {
|
||||
nFirst = $('div.dataTables_paginate span.first');
|
||||
nPrevious = $('div.dataTables_paginate span.previous');
|
||||
nNext = $('div.dataTables_paginate span.next');
|
||||
nLast = $('div.dataTables_paginate span.last');
|
||||
nFirst = $('div.dataTables_paginate a.first');
|
||||
nPrevious = $('div.dataTables_paginate a.previous');
|
||||
nNext = $('div.dataTables_paginate a.next');
|
||||
nLast = $('div.dataTables_paginate a.last');
|
||||
nLast.click();
|
||||
},
|
||||
function () {
|
||||
|
@ -22,9 +22,9 @@ $(document).ready( function () {
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
"Two div elements are in the wrapper",
|
||||
"Two A elements are in the wrapper",
|
||||
null,
|
||||
function () { return $('#example_paginate div').length == 2; }
|
||||
function () { return $('#example_paginate a').length == 2; }
|
||||
);
|
||||
|
||||
oTest.fnWaitTest(
|
||||
@ -89,10 +89,10 @@ $(document).ready( function () {
|
||||
oTest.fnWaitTest(
|
||||
"Jump to last page",
|
||||
function () {
|
||||
nFirst = $('div.dataTables_paginate span.first');
|
||||
nPrevious = $('div.dataTables_paginate span.previous');
|
||||
nNext = $('div.dataTables_paginate span.next');
|
||||
nLast = $('div.dataTables_paginate span.last');
|
||||
nFirst = $('div.dataTables_paginate a.first');
|
||||
nPrevious = $('div.dataTables_paginate a.previous');
|
||||
nNext = $('div.dataTables_paginate a.next');
|
||||
nLast = $('div.dataTables_paginate a.last');
|
||||
nLast.click();
|
||||
},
|
||||
function () {
|
||||
|
Loading…
Reference in New Issue
Block a user