1 common.test CommonJavaScriptTestCase::testNoCache()

Test backdrop_add_js() sets preprocess to false when cache is set to false.

File

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

Class

CommonJavaScriptTestCase
Tests for the JavaScript system.

Code

function testNoCache() {
  $javascript = backdrop_add_js('core/misc/collapse.js', array('cache' => FALSE));
  $this->assertFalse($javascript['core/misc/collapse.js']['preprocess'], 'Setting cache to FALSE sets preprocess to FALSE when adding JavaScript.');
}