[ Index ] |
PHP Cross Reference of Unnamed Project |
[Source view] [Print] [Project Stats]
Tests for Moodle 2 format backup operation.
Copyright: | 2014 The Open University |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 539 lines (24 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
core_backup_moodle2_testcase:: (7 methods):
test_backup_availability()
test_restore_legacy_availability()
test_duplicate_availability()
test_restore_dates()
test_restore_frontpage()
backup_and_restore()
duplicate()
Class: core_backup_moodle2_testcase - X-Ref
Tests for Moodle 2 format backup operation.test_backup_availability() X-Ref |
Tests the availability field on modules and sections is correctly backed up and restored. |
test_restore_legacy_availability() X-Ref |
The availability data format was changed in Moodle 2.7. This test ensures that a Moodle 2.6 backup with this data can still be correctly restored. |
test_duplicate_availability() X-Ref |
Tests the backup and restore of single activity to same course (duplicate) when it contains availability conditions that depend on other items in course. |
test_restore_dates() X-Ref |
When restoring a course, you can change the start date, which shifts other dates. This test checks that certain dates are correctly modified. |
test_restore_frontpage() X-Ref |
Test front page backup/restore and duplicate activities return: void |
backup_and_restore($course, $newdate = 0) X-Ref |
Backs a course up and restores it. param: stdClass $course Course object to backup param: int $newdate If non-zero, specifies custom date for new course return: int ID of newly restored course |
duplicate($course, $cmid) X-Ref |
Duplicates a single activity within a course. This is based on the code from course/modduplicate.php, but reduced for simplicity. param: stdClass $course Course object param: int $cmid Activity to duplicate return: int ID of new activity |
Generated: Thu Aug 11 10:00:09 2016 | Cross-referenced by PHPXref 0.7.1 |