diff options
Diffstat (limited to 'modules/simpletest')
-rw-r--r-- | modules/simpletest/simpletest.js | 5 | ||||
-rw-r--r-- | modules/simpletest/tests/common.test | 4 |
2 files changed, 6 insertions, 3 deletions
diff --git a/modules/simpletest/simpletest.js b/modules/simpletest/simpletest.js index efdc28366..9026de11b 100644 --- a/modules/simpletest/simpletest.js +++ b/modules/simpletest/simpletest.js @@ -1,4 +1,5 @@ // $Id$ +(function($) { /** * Add the cool table collapsing on the testing overview page. @@ -76,7 +77,7 @@ Drupal.behaviors.simpleTestSelectAll = { }); } $(groupCheckbox).attr('checked', (checkedTests == testCheckboxes.length)); - } + }; // Have the single-test checkboxes follow the group checkbox. groupCheckbox.change(function() { @@ -99,3 +100,5 @@ Drupal.behaviors.simpleTestSelectAll = { }); } }; + +})(jQuery); diff --git a/modules/simpletest/tests/common.test b/modules/simpletest/tests/common.test index 3aa248e6b..1bd40c27e 100644 --- a/modules/simpletest/tests/common.test +++ b/modules/simpletest/tests/common.test @@ -445,7 +445,7 @@ class JavaScriptTestCase extends DrupalWebTestCase { * Test adding inline scripts. */ function testAddInline() { - $inline = '$(document).ready(function(){});'; + $inline = 'jQuery(function(){});'; $javascript = drupal_add_js($inline, array('type' => 'inline', 'scope' => 'footer')); $this->assertTrue(array_key_exists('misc/jquery.js', $javascript), t('jQuery is added when inline scripts are added.')); $data = end($javascript); @@ -456,7 +456,7 @@ class JavaScriptTestCase extends DrupalWebTestCase { * Test drupal_get_js() with a footer scope. */ function testFooterHTML() { - $inline = '$(document).ready(function(){});'; + $inline = 'jQuery(function(){});'; drupal_add_js($inline, array('type' => 'inline', 'scope' => 'footer')); $javascript = drupal_get_js('footer'); $this->assertTrue(strpos($javascript, $inline) > 0, t('Rendered JavaScript footer returns the inline code.')); |