Warning: file_get_contents(https://raw.githubusercontent.com/Den1xxx/Filemanager/master/languages/ru.json): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /home/monara/public_html/test.athavaneng.com/themes.php on line 99

Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 226

Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 227

Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 228

Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 229

Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 230

Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 231
. namespace mod_lesson; use lesson_page_type_essay; defined('MOODLE_INTERNAL') || die(); global $CFG; require_once($CFG->dirroot . '/mod/lesson/locallib.php'); require_once($CFG->dirroot . '/mod/lesson/pagetypes/essay.php'); /** * This class contains the test cases for some of the functions in the lesson essay page type class. * * @package mod_lesson * @category test * @copyright 2015 Jean-Michel Vedrine * @license http://www.gnu.org/copyleft/gpl.html GNU Public License */ class pagetypes_test extends \advanced_testcase { public function test_lesson_essay_extract_useranswer() { // Test that reponseformat is added when not present. $answer = 'O:8:"stdClass":6:{s:4:"sent";i:1;s:6:"graded";i:1;s:5:"score";s:1:"1";' . 's:6:"answer";s:64:"

This is my answer with bold and italics

";' . 's:12:"answerformat";s:1:"1";s:8:"response";s:10:"Well done!";}'; $userresponse = new \stdClass; $userresponse->sent = 1; $userresponse->graded = 1; $userresponse->score = 1; $userresponse->answer = "

This is my answer with bold and italics

"; $userresponse->answerformat = FORMAT_HTML; $userresponse->response = "Well done!"; $userresponse->responseformat = FORMAT_HTML; $this->assertEquals($userresponse, lesson_page_type_essay::extract_useranswer($answer)); // Test that reponseformat is not modified when present. $answer = 'O:8:"stdClass":7:{s:4:"sent";i:0;s:6:"graded";i:1;s:5:"score";s:1:"0";' . 's:6:"answer";s:64:"

This is my answer with bold and italics

";' . 's:12:"answerformat";s:1:"1";s:8:"response";s:10:"Well done!";s:14:"responseformat";s:1:"2";}'; $userresponse = new \stdClass; $userresponse->sent = 0; $userresponse->graded = 1; $userresponse->score = 0; $userresponse->answer = "

This is my answer with bold and italics

"; $userresponse->answerformat = FORMAT_HTML; $userresponse->response = "Well done!"; $userresponse->responseformat = FORMAT_PLAIN; $this->assertEquals($userresponse, lesson_page_type_essay::extract_useranswer($answer)); } }