]> git.mjollnir.org Git - moodle.git/commitdiff
Try to avoid time-outs while running the unit tests
authortjhunt <tjhunt>
Mon, 22 Jun 2009 06:59:13 +0000 (06:59 +0000)
committertjhunt <tjhunt>
Mon, 22 Jun 2009 06:59:13 +0000 (06:59 +0000)
lib/simpletestlib/test_case.php

index fce7d814c6c51919772f2f3a5e20fd0df6413b53..61cac9f5ab501d63e2b5f70e9cf5d5c17cebbe43 100644 (file)
@@ -605,6 +605,9 @@ class TestSuite {
                     // Do not execute this test because $CFG->unittestprefix is not set, but it will be required.
                     continue;
                 }
+                if ($currenttl = @ini_get('max_execution_time')) {
+                    @ini_set('max_execution_time', $currenttl);
+                }
                 // moodle hack end
                 $test = &new $class();
                 $test->run($reporter);