[ Index ]

PHP Cross Reference of vtigercrm-6.1.0

title

Body

[close]

/libraries/bootstrap/js/eternicode-bootstrap-datepicker/tests/assets/ -> qunit-logging.js (source)

   1  // Dummy logging calls (ie, if tests are run in IE)
   2  window.console = window.console || {};
   3  window.console.log = window.console.log || function(){};
   4  window.console.debug = window.console.debug || function(){};
   5  window.console.info = window.console.info || function(){};
   6  window.console.warn = window.console.warn || function(){};
   7  window.console.error = window.console.error || function(){};
   8  
   9  (function() {
  10     var modName, testName;
  11  
  12     //arg: { name }
  13      QUnit.testStart = function(t) {
  14          modName = t.module;
  15          testName = t.name;
  16      };
  17  
  18      //arg: { name, failed, passed, total }
  19      QUnit.testDone = function(t) {
  20          if (t.failed)
  21              console.log('Test "' + t.module + ': ' + t.name + '" completed: ' + (0 === t.failed ? 'pass' : 'FAIL') + '\n')
  22      };
  23  
  24      //{ result, actual, expected, message }
  25      QUnit.log = function(t) {
  26          if (!t.result)
  27              console.log('Test "' + modName + ': ' + testName + '" assertion failed. Expected <' + t.expected + '> Actual <' + t.actual + '>' + (t.message ? ': \'' + t.message + '\'' : ''));
  28      };
  29  }());


Generated: Fri Nov 28 20:08:37 2014 Cross-referenced by PHPXref 0.7.1