Add datatables-1.9.4 and jquery-1.10.2 libraries
[proteocache.git] / webapp / resources / datatables-1.9.4 / media / unit_testing / tests_onhold / 1_dom / 2600.js
1 // DATA_TEMPLATE: dom_data
2 oTest.fnStart( "2600 - Display rewind when changing length" );
3
4 $(document).ready( function () {
5         $('#example').dataTable();
6         
7         oTest.fnTest( 
8                 "Info correct on init",
9                 null,
10                 function () { return $('#example_info').html() == "Showing 1 to 10 of 57 entries"; }
11         );
12         
13         oTest.fnTest( 
14                 "Page 2",
15                 function () { $('#example_next').click(); },
16                 function () { return $('#example_info').html() == "Showing 11 to 20 of 57 entries"; }
17         );
18         
19         oTest.fnTest( 
20                 "Page 3",
21                 function () { $('#example_next').click(); },
22                 function () { return $('#example_info').html() == "Showing 21 to 30 of 57 entries"; }
23         );
24         
25         oTest.fnTest( 
26                 "Page 4",
27                 function () { $('#example_next').click(); },
28                 function () { return $('#example_info').html() == "Showing 31 to 40 of 57 entries"; }
29         );
30         
31         oTest.fnTest( 
32                 "Page 5",
33                 function () { $('#example_next').click(); },
34                 function () { return $('#example_info').html() == "Showing 41 to 50 of 57 entries"; }
35         );
36         
37         oTest.fnTest( 
38                 "Rewind",
39                 function () { $('#example_length select').val('100'); $('#example_length select').change(); },
40                 function () { return $('#example_info').html() == "Showing 1 to 57 of 57 entries"; }
41         );
42         
43         oTest.fnComplete();
44 } );