function CacheActionsCssJsTestCase::testClearCssJs in Cache Actions 6.2
Same name and namespace in other branches
- 7.2 cache_actions.test \CacheActionsCssJsTestCase::testClearCssJs()
- 7 cache_actions.test \CacheActionsCssJsTestCase::testClearCssJs()
Test clearing the css and js caches.
File
- ./
cache_actions.test, line 280 - This file contains the tests for Cache Actions. All tests depend on the panels, views and rules that are defined by the cache actions test module.
Class
- CacheActionsCssJsTestCase
- Tests for css and js.
Code
function testClearCssJs() {
// Create the css and js cache.
$this
->drupalGet('/');
// Create a node which triggers the rule.
$this
->drupalCreateNode();
$css = scandir(file_directory_path() . '/css');
$js = scandir(file_directory_path() . '/js');
// Check that the css and js cache is cleared.
$this
->assertEqual(count($css), 2);
$this
->assertEqual(count($js), 2);
}