Proyectos de Subversion Moodle

Rev

Rev 11 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 11 Rev 1441
Línea 38... Línea 38...
38
 * @category   external
38
 * @category   external
39
 * @copyright  2015 Juan Leyva <juan@moodle.com>
39
 * @copyright  2015 Juan Leyva <juan@moodle.com>
40
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
40
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
41
 * @since      Moodle 3.0
41
 * @since      Moodle 3.0
42
 */
42
 */
43
class lib_test extends \advanced_testcase {
43
final class lib_test extends \advanced_testcase {
Línea 44... Línea 44...
44
 
44
 
45
    /**
45
    /**
46
     * Setup.
46
     * Setup.
47
     */
47
     */
-
 
48
    public function setUp(): void {
48
    public function setUp(): void {
49
        parent::setUp();
49
        $this->resetAfterTest();
50
        $this->resetAfterTest();
50
        $this->setAdminUser();
51
        $this->setAdminUser();
Línea 51... Línea 52...
51
    }
52
    }
Línea 55... Línea 56...
55
     * @return void
56
     * @return void
56
     */
57
     */
57
    public static function setUpBeforeClass(): void {
58
    public static function setUpBeforeClass(): void {
58
        global $CFG;
59
        global $CFG;
59
        require_once($CFG->dirroot . '/mod/folder/lib.php');
60
        require_once($CFG->dirroot . '/mod/folder/lib.php');
-
 
61
        parent::setUpBeforeClass();
60
    }
62
    }
Línea 61... Línea 63...
61
 
63
 
62
    /**
64
    /**
63
     * Test folder_view
65
     * Test folder_view
Línea 374... Línea 376...
374
    /**
376
    /**
375
     * Data provider for test_folder_get_recent_mod_activity().
377
     * Data provider for test_folder_get_recent_mod_activity().
376
     *
378
     *
377
     * @return array
379
     * @return array
378
     */
380
     */
379
    public function folder_get_recent_mod_activity_provider(): array {
381
    public static function folder_get_recent_mod_activity_provider(): array {
380
        return [
382
        return [
381
            'Teacher with force download' => [
383
            'Teacher with force download' => [
382
                'forcedownload' => 1,
384
                'forcedownload' => 1,
383
                'hascapability' => true,
385
                'hascapability' => true,
384
                'count' => 2,
386
                'count' => 2,