You are here

function JavaScriptTestCase::testReset in Drupal 7

Test to see if resetting the JavaScript empties the cache.

File

modules/simpletest/tests/common.test, line 1538
Tests for common.inc functionality.

Class

JavaScriptTestCase
Tests for the JavaScript system.

Code

function testReset() {
  drupal_add_js('misc/collapse.js');
  drupal_static_reset('drupal_add_js');
  $this
    ->assertEqual(array(), drupal_add_js(), 'Resetting the JavaScript correctly empties the cache.');
}