Index: includes/common.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/common.inc,v
retrieving revision 1.827
diff -u -9 -p -r1.827 common.inc
--- includes/common.inc	16 Nov 2008 19:41:14 -0000	1.827
+++ includes/common.inc	18 Nov 2008 20:05:08 -0000
@@ -717,19 +717,23 @@ function _drupal_log_error($error, $fata
   }
 
   // When running inside the testing framework, we relay the errors
   // to the tested site by the way of HTTP headers.
   if (preg_match("/^simpletest\d+/", $_SERVER['HTTP_USER_AGENT']) && !headers_sent() && !defined('SIMPLETEST_DONT_COLLECT_ERRORS')) {
     static $number = 0;
     $assertion = array(
       $error['%message'],
       $error['%type'],
-      $error['%function'],
+      array(
+        'function' => $error['%function'],
+        'file' => $error['%file'],
+        'line' => $error['%line'],
+      ),
     );
     header('X-Drupal-Assertion-' . $number . ': ' . rawurlencode(serialize($assertion)));
     $number++;
   }
 
   // Force display of error messages in update.php.
   if (variable_get('error_level', 1) == 1 || (defined('MAINTENANCE_MODE') && MAINTENANCE_MODE == 'update')) {
     drupal_set_message(t('%type: %message in %function (line %line of %file).', $error), 'error');
   }
Index: modules/simpletest/drupal_web_test_case.php
===================================================================
RCS file: /cvs/drupal/drupal/modules/simpletest/drupal_web_test_case.php,v
retrieving revision 1.56
diff -u -9 -p -r1.56 drupal_web_test_case.php
--- modules/simpletest/drupal_web_test_case.php	9 Nov 2008 03:07:54 -0000	1.56
+++ modules/simpletest/drupal_web_test_case.php	18 Nov 2008 20:05:09 -0000
@@ -44,19 +44,19 @@ class DrupalWebTestCase {
    * @param $group
    *   WHich group this assert belongs to.
    * @param $caller
    *   By default, the assert comes from a function which names start with
    *   'test'. Instead, you can specify where this assert originates from
    *   by passing in an associative array as $caller. Key 'file' is
    *   the name of the source file, 'line' is the line number and 'function'
    *   is the caller function itself.
    */
-  protected function _assert($status, $message = '', $group = 'Other', $caller = NULL) {
+  protected function _assert($status, $message = '', $group = 'Other', array $caller = NULL) {
     global $db_prefix;
 
     // Convert boolean status to string status.
     if (is_bool($status)) {
       $status = $status ? 'pass' : 'fail';
     }
 
     // Increment summary result counter.
     $this->_results['#' . $status]++;
@@ -277,22 +277,25 @@ class DrupalWebTestCase {
   }
 
   /**
    * Fire an error assertion.
    *
    * @param $message
    *   The message to display along with the assertion.
    * @param $group
    *   The type of assertion - examples are "Browser", "PHP".
-   * @param $caller
-   *   The caller of the error.
+   *   By default, the error comes from a function which names start with
+   *   'test'. Instead, you can specify where this error originates from by
+   *   passing in an associative array as $caller. Key 'file' is the name of
+   *   the source file, 'line' is the line number and 'function' is the caller
+   *   function itself.
    */
-  protected function error($message = '', $group = 'Other', $caller = NULL) {
+  protected function error($message = '', $group = 'Other', array $caller = NULL) {
     return $this->_assert('exception', $message, $group, $caller);
   }
 
   /**
    * Run all tests in this class.
    */
   function run() {
     set_error_handler(array($this, 'errorHandler'));
     $methods = array();
