Proyectos de Subversion Moodle

Rev

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

Rev 11 Rev 1441
Línea 34... Línea 34...
34
 *
34
 *
35
 * @package   mod_choice
35
 * @package   mod_choice
36
 * @copyright 2021 Jun Pataleta <jun@moodle.com>
36
 * @copyright 2021 Jun Pataleta <jun@moodle.com>
37
 * @license   http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
37
 * @license   http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
38
 */
38
 */
39
class custom_completion_test extends advanced_testcase {
39
final class custom_completion_test extends advanced_testcase {
Línea 40... Línea 40...
40
 
40
 
41
    /**
41
    /**
42
     * Data provider for get_state().
42
     * Data provider for get_state().
43
     *
43
     *
44
     * @return array[]
44
     * @return array[]
45
     */
45
     */
46
    public function get_state_provider(): array {
46
    public static function get_state_provider(): array {
47
        return [
47
        return [
48
            'Undefined rule' => [
48
            'Undefined rule' => [
49
                'somenonexistentrule', COMPLETION_DISABLED, false, null, coding_exception::class
49
                'somenonexistentrule', COMPLETION_DISABLED, false, null, coding_exception::class
50
            ],
50
            ],
Línea 164... Línea 164...
164
    /**
164
    /**
165
     * Data provider for test_get_available_custom_rules().
165
     * Data provider for test_get_available_custom_rules().
166
     *
166
     *
167
     * @return array[]
167
     * @return array[]
168
     */
168
     */
169
    public function get_available_custom_rules_provider(): array {
169
    public static function get_available_custom_rules_provider(): array {
170
        return [
170
        return [
171
            'Completion submit available' => [
171
            'Completion submit available' => [
172
                COMPLETION_ENABLED, ['completionsubmit']
172
                COMPLETION_ENABLED, ['completionsubmit']
173
            ],
173
            ],
174
            'Completion submit not available' => [
174
            'Completion submit not available' => [