function common_test_library_alter

Implements hook_library_alter().

File

modules/simpletest/tests/common_test.module, line 243

Code

function common_test_library_alter(&$libraries, $module) {
  if ($module == 'system' && isset($libraries['farbtastic'])) {
    // Change the title of Farbtastic to "Farbtastic: Altered Library".
    $libraries['farbtastic']['title'] = 'Farbtastic: Altered Library';
    // Make Farbtastic depend on jQuery Form to test library dependencies.
    $libraries['farbtastic']['dependencies'][] = array(
      'system',
      'form',
    );
  }
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.