Index: drupal_web_test_case.php
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/simpletest/drupal_web_test_case.php,v
retrieving revision 1.2.2.3.2.38
diff -u -r1.2.2.3.2.38 drupal_web_test_case.php
--- drupal_web_test_case.php	25 Apr 2009 22:14:54 -0000	1.2.2.3.2.38
+++ drupal_web_test_case.php	26 May 2009 23:25:32 -0000
@@ -880,11 +880,20 @@
 //    $this->preloadRegistry();
 
     // Add the specified modules to the list of modules in the default profile.
-    $args = func_get_args();
+//    $args = func_get_args();
 //    $modules = array_unique(array_merge(drupal_get_profile_modules('default', 'en'), $args));
-    $modules = array_unique(array_merge(drupal_verify_profile('default', 'en'), $args));
 //    drupal_install_modules($modules, TRUE);
-    drupal_install_modules($modules);
+
+    // Install the modules specified by the default profile.
+    $core_modules = drupal_verify_profile('default', 'en');
+    drupal_install_modules($core_modules);
+
+    // Install additional modules one at a time in order to make sure that the
+    // list of modules is updated between each module's installation.
+    $modules = func_get_args();
+    foreach ($modules as $module) {
+      drupal_install_modules(array($module));
+    }
 
     // Because the schema is static cached, we need to flush
     // it between each run. If we don't, then it will contain
