mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-16486 Implemented the proxy DB class. Sort of working, but still some issues to sort out, like fix_course_sort_order, which updates a record NOT inserted by the unit test.
This commit is contained in:
parent
aa41944f23
commit
5d1381c2c3
5 changed files with 212 additions and 30 deletions
|
@ -103,7 +103,7 @@ class resource_base {
|
|||
$morenavlinks = array($this->strresources => 'index.php?id='.$this->course->id,
|
||||
$this->resource->name => '');
|
||||
|
||||
$PAGE->print_header($this->course->shortname.': %fullname%', $morenavlinks, "", "",
|
||||
$PAGE->print_header($this->course->shortname.': %fullname%', $morenavlinks, "", "",
|
||||
update_module_button($this->cm->id, $this->course->id, $this->strresource));
|
||||
|
||||
echo '<table id="layout-table"><tr>';
|
||||
|
@ -728,6 +728,7 @@ class resource_portfolio_caller extends portfolio_module_caller_base {
|
|||
require_once($this->resourcefile);
|
||||
$this->resource= new $resourceclass($this->cm->id);
|
||||
if (!is_callable(array($this->resource, 'portfolio_prepare_package')) || !is_callable(array($this->resource, 'portfolio_get_sha1'))) {
|
||||
debug_print_backtrace();
|
||||
throw new portfolio_exception('portfolionotimplemented', 'resource', null, $this->cm->type);
|
||||
}
|
||||
$this->supportedformats = array(self::type_to_format($this->cm->type));
|
||||
|
|
|
@ -19,7 +19,7 @@ class testResourcePortfolioCallers extends portfoliolib_test {
|
|||
|
||||
$resource_type = new stdClass();
|
||||
$resource_type->type = GENERATOR_SEQUENCE;
|
||||
$resource_type->options = array('file', 'text', 'html');
|
||||
$resource_type->options = array('text', 'html');
|
||||
|
||||
$settings = array('quiet' => 1, 'pre_cleanup' => 1,
|
||||
'modules_list' => array($this->module_type),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue