Proyectos de Subversion Moodle

Rev

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

Rev 1 Rev 11
Línea 73... Línea 73...
73
     * @covers ::db_should_replace
73
     * @covers ::db_should_replace
74
     * @param string $table name
74
     * @param string $table name
75
     * @param string $column name
75
     * @param string $column name
76
     * @param bool $expected whether it should be replaced
76
     * @param bool $expected whether it should be replaced
77
     */
77
     */
78
    public function test_db_should_replace(string $table, string $column, bool $expected) {
78
    public function test_db_should_replace(string $table, string $column, bool $expected): void {
79
        $actual = db_should_replace($table, $column);
79
        $actual = db_should_replace($table, $column);
80
        $this->assertSame($actual, $expected);
80
        $this->assertSame($actual, $expected);
81
    }
81
    }
Línea 82... Línea 82...
82
 
82
 
Línea 118... Línea 118...
118
     * @covers ::db_should_replace
118
     * @covers ::db_should_replace
119
     * @param string $table name
119
     * @param string $table name
120
     * @param string $column name
120
     * @param string $column name
121
     * @param bool $expected whether it should be replaced
121
     * @param bool $expected whether it should be replaced
122
     */
122
     */
123
    public function test_db_should_replace_additional_skip_tables(string $table, string $column, bool $expected) {
123
    public function test_db_should_replace_additional_skip_tables(string $table, string $column, bool $expected): void {
124
        $this->resetAfterTest();
124
        $this->resetAfterTest();
125
        $additionalskiptables = 'context, quiz_attempts, role_assignments ';
125
        $additionalskiptables = 'context, quiz_attempts, role_assignments ';
126
        $actual = db_should_replace($table, $column, $additionalskiptables);
126
        $actual = db_should_replace($table, $column, $additionalskiptables);
127
        $this->assertSame($actual, $expected);
127
        $this->assertSame($actual, $expected);
128
    }
128
    }
Línea 130... Línea 130...
130
    /**
130
    /**
131
     * Test admin_output_new_settings_by_page method.
131
     * Test admin_output_new_settings_by_page method.
132
     *
132
     *
133
     * @covers ::admin_output_new_settings_by_page
133
     * @covers ::admin_output_new_settings_by_page
134
     */
134
     */
135
    public function test_admin_output_new_settings_by_page() {
135
    public function test_admin_output_new_settings_by_page(): void {
136
        $this->resetAfterTest();
136
        $this->resetAfterTest();
137
        $this->setAdminUser();
137
        $this->setAdminUser();
Línea 138... Línea 138...
138
 
138
 
139
        $root = admin_get_root(true, true);
139
        $root = admin_get_root(true, true);
Línea 161... Línea 161...
161
    /**
161
    /**
162
     * Test repeated recursive application of default settings.
162
     * Test repeated recursive application of default settings.
163
     *
163
     *
164
     * @covers ::admin_apply_default_settings
164
     * @covers ::admin_apply_default_settings
165
     */
165
     */
166
    public function test_admin_apply_default_settings() {
166
    public function test_admin_apply_default_settings(): void {
167
        global $DB;
167
        global $DB;
Línea 168... Línea 168...
168
 
168
 
169
        $this->resetAfterTest();
169
        $this->resetAfterTest();