Proyectos de Subversion Moodle

Rev

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

Rev 1 Rev 11
Línea 49... Línea 49...
49
 
49
 
50
    /**
50
    /**
51
     * Tests the url_appears_valid_url function
51
     * Tests the url_appears_valid_url function
52
     * @return void
52
     * @return void
53
     */
53
     */
54
    public function test_url_appears_valid_url() {
54
    public function test_url_appears_valid_url(): void {
55
        $this->assertTrue(url_appears_valid_url('http://example'));
55
        $this->assertTrue(url_appears_valid_url('http://example'));
56
        $this->assertTrue(url_appears_valid_url('http://www.example.com'));
56
        $this->assertTrue(url_appears_valid_url('http://www.example.com'));
57
        $this->assertTrue(url_appears_valid_url('http://www.examplé.com'));
57
        $this->assertTrue(url_appears_valid_url('http://www.examplé.com'));
58
        $this->assertTrue(url_appears_valid_url('http://💩.la'));
58
        $this->assertTrue(url_appears_valid_url('http://💩.la'));
Línea 96... Línea 96...
96
 
96
 
97
    /**
97
    /**
98
     * Test url_view
98
     * Test url_view
99
     * @return void
99
     * @return void
100
     */
100
     */
101
    public function test_url_view() {
101
    public function test_url_view(): void {
Línea 102... Línea 102...
102
        global $CFG;
102
        global $CFG;
103
 
103
 
Línea 137... Línea 137...
137
    }
137
    }
Línea 138... Línea 138...
138
 
138
 
139
    /**
139
    /**
140
     * Test mod_url_core_calendar_provide_event_action with user override
140
     * Test mod_url_core_calendar_provide_event_action with user override
141
     */
141
     */
142
    public function test_url_core_calendar_provide_event_action_user_override() {
142
    public function test_url_core_calendar_provide_event_action_user_override(): void {
Línea 143... Línea 143...
143
        global $CFG, $USER;
143
        global $CFG, $USER;
144
 
144
 
145
        $this->resetAfterTest();
145
        $this->resetAfterTest();
Línea 183... Línea 183...
183
        $this->assertInstanceOf('moodle_url', $actionevent2->get_url());
183
        $this->assertInstanceOf('moodle_url', $actionevent2->get_url());
184
        $this->assertEquals(1, $actionevent2->get_item_count());
184
        $this->assertEquals(1, $actionevent2->get_item_count());
185
        $this->assertTrue($actionevent2->is_actionable());
185
        $this->assertTrue($actionevent2->is_actionable());
186
    }
186
    }
Línea 187... Línea 187...
187
 
187
 
188
    public function test_url_core_calendar_provide_event_action() {
188
    public function test_url_core_calendar_provide_event_action(): void {
189
        $this->resetAfterTest();
189
        $this->resetAfterTest();
Línea 190... Línea 190...
190
        $this->setAdminUser();
190
        $this->setAdminUser();
191
 
191
 
Línea 209... Línea 209...
209
        $this->assertInstanceOf('moodle_url', $actionevent->get_url());
209
        $this->assertInstanceOf('moodle_url', $actionevent->get_url());
210
        $this->assertEquals(1, $actionevent->get_item_count());
210
        $this->assertEquals(1, $actionevent->get_item_count());
211
        $this->assertTrue($actionevent->is_actionable());
211
        $this->assertTrue($actionevent->is_actionable());
212
    }
212
    }
Línea 213... Línea 213...
213
 
213
 
214
    public function test_url_core_calendar_provide_event_action_already_completed() {
214
    public function test_url_core_calendar_provide_event_action_already_completed(): void {
Línea 215... Línea 215...
215
        global $CFG;
215
        global $CFG;
216
 
216