diff --git a/tests/phpunit/local/outagelib_test.php b/tests/phpunit/local/outagelib_test.php index 69b470f..c6b5ae0 100644 --- a/tests/phpunit/local/outagelib_test.php +++ b/tests/phpunit/local/outagelib_test.php @@ -31,7 +31,7 @@ defined('MOODLE_INTERNAL') || die(); global $CFG; require_once($CFG->libdir.'/adminlib.php'); - +require_once(__DIR__.'/../base_testcase.php'); /** * outagelib_test test class. * @@ -293,6 +293,7 @@ class outagelib_test extends auth_outage_base_testcase { if ((time() >= 123) && (time() < 456)) { define('MOODLE_INTERNAL', true); require_once($CFG->dirroot.'/lib/moodlelib.php'); + require_once($CFG->dirroot.'/lib/classes/ip_utils.php'); if (!remoteip_in_list('heyyou a.b.c.d e.e.e.e/20')) { @@ -333,6 +334,7 @@ EOT; if ((time() >= 123) && (time() < 456)) { define('MOODLE_INTERNAL', true); require_once($CFG->dirroot.'/lib/moodlelib.php'); + require_once($CFG->dirroot.'/lib/classes/ip_utils.php'); if (!remoteip_in_list('127.0.0.1')) { header($_SERVER['SERVER_PROTOCOL'] . ' 503 Moodle under maintenance'); header('Status: 503 Moodle under maintenance');