summaryrefslogtreecommitdiff
path: root/modules/simpletest/drupal_web_test_case.php
diff options
context:
space:
mode:
authorAngie Byron <webchick@24967.no-reply.drupal.org>2009-08-15 06:20:20 +0000
committerAngie Byron <webchick@24967.no-reply.drupal.org>2009-08-15 06:20:20 +0000
commit8b86d0da84570d3f6d461a502b94bedc2f91889e (patch)
tree701433b527d673f2c0bdf88236e7239a39c2826a /modules/simpletest/drupal_web_test_case.php
parent838b4c65100df5ebda24a4b10f6405d2b38a888e (diff)
downloadbrdo-8b86d0da84570d3f6d461a502b94bedc2f91889e.tar.gz
brdo-8b86d0da84570d3f6d461a502b94bedc2f91889e.tar.bz2
#296574 by boombatower and chx: Provide debug function for debugging during tests and elsewhere.
Diffstat (limited to 'modules/simpletest/drupal_web_test_case.php')
-rw-r--r--modules/simpletest/drupal_web_test_case.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/modules/simpletest/drupal_web_test_case.php b/modules/simpletest/drupal_web_test_case.php
index 5bb6c51a9..ad27ac258 100644
--- a/modules/simpletest/drupal_web_test_case.php
+++ b/modules/simpletest/drupal_web_test_case.php
@@ -42,6 +42,7 @@ abstract class DrupalTestCase {
'#pass' => 0,
'#fail' => 0,
'#exception' => 0,
+ '#debug' => 0,
);
/**
@@ -376,6 +377,12 @@ abstract class DrupalTestCase {
* FALSE.
*/
protected function error($message = '', $group = 'Other', array $caller = NULL) {
+ if ($group == 'User notice') {
+ // Since 'User notice' is set by trigger_error() which is used for debug
+ // set the message to a status of 'debug'.
+ return $this->assert('debug', $message, 'Debug', $caller);
+ }
+
return $this->assert('exception', $message, $group, $caller);
}