function CascadingStylesheetsTestCase::testAddExternal

7.x common.test CascadingStylesheetsTestCase::testAddExternal()

Tests adding an external stylesheet.

File

drupal-7.x/modules/simpletest/tests/common.test, line 642
Tests for common.inc functionality.

Class

CascadingStylesheetsTestCase
Test the Drupal CSS system.

Code

function testAddExternal() {
  $path = 'http://example.com/style.css';
  $css = drupal_add_css($path, 'external');
  $this->assertEqual($css[$path]['type'], 'external', 'Adding an external CSS file caches it properly.');
}