diff --git a/core/modules/simpletest/tests/common.test b/core/modules/simpletest/tests/common.test
index 4f20361..e63fd67 100644
--- a/core/modules/simpletest/tests/common.test
+++ b/core/modules/simpletest/tests/common.test
@@ -741,10 +741,13 @@ class CommonCascadingStylesheetsTestCase extends DrupalWebTestCase {
     $system_path = drupal_get_path('module', 'system');
     drupal_add_css($system_path . '/system.base.css', array('group' => CSS_SYSTEM, 'weight' => -10));
     drupal_add_css($system_path . '/system.theme.css', array('group' => CSS_SYSTEM));
+    drupal_add_css($system_path . '/system.admin.css', array('group' => CSS_SYSTEM));
+    drupal_add_css($system_path . '/system.theme.css', array('group' => CSS_SYSTEM));
 
     $expected = array(
       $system_path . '/system.base.css',
       $system_path . '/system.theme.css',
+      $system_path . '/system.admin.css',
       drupal_get_path('module', 'simpletest') . '/simpletest.css',
     );
 
@@ -777,6 +780,9 @@ class CommonCascadingStylesheetsTestCase extends DrupalWebTestCase {
     $this->assert(strpos($styles, $simpletest . '/tests/system.base.css') !== FALSE, t('The overriding CSS file is output.'));
     $this->assert(strpos($styles, $system . '/system.base.css') === FALSE, t('The overridden CSS file is not output.'));
 
+    // If the static isn't cleared, the files will maintain the above order.
+    drupal_static_reset('drupal_add_css');
+
     drupal_add_css($simpletest . '/tests/system.base.css');
     drupal_add_css($system . '/system.base.css');
 
@@ -1464,6 +1470,31 @@ class CommonJavaScriptTestCase extends DrupalWebTestCase {
       $result = array();
     }
     $this->assertIdentical($result, $expected, t('JavaScript is added in the expected weight order.'));
+
+    // If the static isn't cleared, the files will maintain the above order.
+    drupal_static_reset('drupal_add_js');
+
+    $system_path = drupal_get_path('module', 'system');
+    drupal_add_js($system_path . '/system.cron.js', array('group' => JS_DEFAULT, 'scope' => 'footer'));
+    drupal_add_js($system_path . '/system.js', array('group' => JS_DEFAULT, 'scope' => 'footer'));
+    drupal_add_js($system_path . '/system.cron.js', array('group' => JS_DEFAULT, 'scope' => 'footer'));
+
+    $expected = array(
+      $system_path . '/system.cron.js',
+      $system_path . '/system.js',
+    );
+
+    $js = drupal_get_js('footer');
+    // Stylesheet URL may be the href of a LINK tag or in an @import statement
+    // of a STYLE tag.
+    if (preg_match_all('/(src=")' . preg_quote($GLOBALS['base_url'] . '/', '/') . '([^?]+)\?/', $js, $matches)) {
+      $result = $matches[2];
+    }
+    else {
+      $result = array();
+    }
+
+    $this->assertIdentical($result, $expected, t('The JS files are in the expected order.'));
   }
 
   /**
