Mercurial > repos > saskia-hiltemann > ireport
diff DataTables-1.9.4/media/unit_testing/tests_onhold/6_delayed_rendering/bInfo.js @ 0:ac5f9272033b draft
first upload
author | saskia-hiltemann |
---|---|
date | Tue, 01 Jul 2014 11:42:23 -0400 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/DataTables-1.9.4/media/unit_testing/tests_onhold/6_delayed_rendering/bInfo.js Tue Jul 01 11:42:23 2014 -0400 @@ -0,0 +1,47 @@ +// DATA_TEMPLATE: empty_table +oTest.fnStart( "bInfo" ); + +$(document).ready( function () { + /* Check the default */ + $('#example').dataTable( { + "sAjaxSource": "../../../examples/ajax/sources/arrays.txt", + "bDeferRender": true + } ); + + oTest.fnWaitTest( + "Info div exists by default", + null, + function () { return document.getElementById('example_info') != null; } + ); + + /* Check can disable */ + oTest.fnWaitTest( + "Info can be disabled", + function () { + oSession.fnRestore(); + $('#example').dataTable( { + "sAjaxSource": "../../../examples/ajax/sources/arrays.txt", + "bDeferRender": true, + "bInfo": false + } ); + }, + function () { return document.getElementById('example_info') == null; } + ); + + /* Enable makes no difference */ + oTest.fnWaitTest( + "Info enabled override", + function () { + oSession.fnRestore(); + $('#example').dataTable( { + "sAjaxSource": "../../../examples/ajax/sources/arrays.txt", + "bDeferRender": true, + "bInfo": true + } ); + }, + function () { return document.getElementById('example_info') != null; } + ); + + + oTest.fnComplete(); +} ); \ No newline at end of file