annotate DataTables-1.9.4/media/unit_testing/tests_onhold/6_delayed_rendering/bInfo.js @ 7:0f2b740536fb draft

Uploaded
author saskia-hiltemann
date Mon, 21 Aug 2017 09:16:07 -0400
parents ac5f9272033b
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
1 // DATA_TEMPLATE: empty_table
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
2 oTest.fnStart( "bInfo" );
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
3
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
4 $(document).ready( function () {
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
5 /* Check the default */
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
6 $('#example').dataTable( {
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
7 "sAjaxSource": "../../../examples/ajax/sources/arrays.txt",
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
8 "bDeferRender": true
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
9 } );
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
10
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
11 oTest.fnWaitTest(
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
12 "Info div exists by default",
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
13 null,
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
14 function () { return document.getElementById('example_info') != null; }
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
15 );
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
16
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
17 /* Check can disable */
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
18 oTest.fnWaitTest(
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
19 "Info can be disabled",
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
20 function () {
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
21 oSession.fnRestore();
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
22 $('#example').dataTable( {
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
23 "sAjaxSource": "../../../examples/ajax/sources/arrays.txt",
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
24 "bDeferRender": true,
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
25 "bInfo": false
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
26 } );
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
27 },
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
28 function () { return document.getElementById('example_info') == null; }
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
29 );
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
30
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
31 /* Enable makes no difference */
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
32 oTest.fnWaitTest(
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
33 "Info enabled override",
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
34 function () {
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
35 oSession.fnRestore();
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
36 $('#example').dataTable( {
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
37 "sAjaxSource": "../../../examples/ajax/sources/arrays.txt",
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
38 "bDeferRender": true,
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
39 "bInfo": true
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
40 } );
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
41 },
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
42 function () { return document.getElementById('example_info') != null; }
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
43 );
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
44
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
45
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
46 oTest.fnComplete();
ac5f9272033b first upload
saskia-hiltemann
parents:
diff changeset
47 } );