MDL-59214 webservice: Return calendar type in get_site_info
[moodle.git] / webservice / tests / externallib_test.php
index f845b62..b5bea8d 100644 (file)
@@ -122,6 +122,12 @@ class core_webservice_externallib_testcase extends externallib_advanced_testcase
         $this->assertEquals(true, $siteinfo['usercanmanageownfiles']);
 
         $this->assertEquals(HOMEPAGE_MY, $siteinfo['userhomepage']);
+        $this->assertEquals($CFG->calendartype, $siteinfo['sitecalendartype']);
+        if (!empty($USER->calendartype)) {
+            $this->assertEquals($USER->calendartype, $siteinfo['usercalendartype']);
+        } else {
+            $this->assertEquals($CFG->calendartype, $siteinfo['usercalendartype']);
+        }
 
         // Now as admin.
         $this->setAdminUser();