Proyectos de Subversion Moodle

Rev

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

Rev 1 Rev 11
Línea 24... Línea 24...
24
 * @copyright  2013 Marina Glancy
24
 * @copyright  2013 Marina Glancy
25
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
25
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
26
 */
26
 */
27
class generator_test extends \advanced_testcase {
27
class generator_test extends \advanced_testcase {
Línea 28... Línea 28...
28
 
28
 
29
    public function test_create_instance() {
29
    public function test_create_instance(): void {
30
        global $DB;
30
        global $DB;
31
        $this->resetAfterTest();
31
        $this->resetAfterTest();
Línea 32... Línea 32...
32
        $this->setAdminUser();
32
        $this->setAdminUser();
Línea 44... Línea 44...
44
        $records = $DB->get_records('glossary', array('course' => $course->id), 'id');
44
        $records = $DB->get_records('glossary', array('course' => $course->id), 'id');
45
        $this->assertCount(2, $records);
45
        $this->assertCount(2, $records);
46
        $this->assertEquals('Another glossary', $records[$glossary->id]->name);
46
        $this->assertEquals('Another glossary', $records[$glossary->id]->name);
47
    }
47
    }
Línea 48... Línea 48...
48
 
48
 
49
    public function test_create_content() {
49
    public function test_create_content(): void {
50
        global $DB;
50
        global $DB;
51
        $this->resetAfterTest();
51
        $this->resetAfterTest();
Línea 52... Línea 52...
52
        $this->setAdminUser();
52
        $this->setAdminUser();