diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-01-10 17:19:01 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-01-10 17:19:01 +0000 |
commit | 12162c1f21ddad325bb212c13d5959a68758377c (patch) | |
tree | 19a252b0ad21e553b1662292abb123f46ca745fd | |
parent | 00b27f694a2b34cda15cf66138e253888832a0a0 (diff) | |
download | brdo-12162c1f21ddad325bb212c13d5959a68758377c.tar.gz brdo-12162c1f21ddad325bb212c13d5959a68758377c.tar.bz2 |
#587634 by mr.baileys and TacoV: Fixed Actions infinite loop test fails.
-rw-r--r-- | modules/simpletest/tests/actions.test | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/modules/simpletest/tests/actions.test b/modules/simpletest/tests/actions.test index 2f43b8777..4eeb70390 100644 --- a/modules/simpletest/tests/actions.test +++ b/modules/simpletest/tests/actions.test @@ -94,17 +94,18 @@ class ActionLoopTestCase extends DrupalWebTestCase { // Delete any existing watchdog messages to clear the plethora of // "Action added" messages from when Drupal was installed. db_delete('watchdog')->execute(); - $this->triggerActions(); - - // Clear the log again for another test, this time with a random maximum. - db_delete('watchdog')->execute(); - variable_set('actions_max_stack', mt_rand(10, 50)); + // To prevent this test from failing when xdebug is enabled, the maximum + // recursion level should be kept low enough to prevent the xdebug + // infinite recursion protection mechanism from aborting the request. + // @see http://drupal.org/node/587634. + variable_set('actions_max_stack', mt_rand(3, 12)); $this->triggerActions(); } /** * Create an infinite loop by causing a watchdog message to be set, - * which causes the actions to be triggered again, up to default of 35 times. + * which causes the actions to be triggered again, up to actions_max_stack + * times. */ protected function triggerActions() { $this->drupalGet('<front>', array('query' => array('trigger_actions_on_watchdog' => TRUE))); |