Proyectos de Subversion Moodle

Rev

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

Rev 11 Rev 1441
Línea 24... Línea 24...
24
 * @package    core_course
24
 * @package    core_course
25
 * @category   test
25
 * @category   test
26
 * @copyright  2013 Marina Glancy
26
 * @copyright  2013 Marina Glancy
27
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
27
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
28
 */
28
 */
29
class category_test extends \advanced_testcase {
29
final class category_test extends \advanced_testcase {
Línea 30... Línea 30...
30
 
30
 
Línea 31... Línea 31...
31
    protected $roles;
31
    protected $roles;
32
 
32
 
Línea 1287... Línea 1287...
1287
    /**
1287
    /**
1288
     * Data provider for test_get_nearest_editable_subcategory_with_hidden_categories().
1288
     * Data provider for test_get_nearest_editable_subcategory_with_hidden_categories().
1289
     *
1289
     *
1290
     * @return array
1290
     * @return array
1291
     */
1291
     */
1292
    public function get_nearest_editable_subcategory_provider(): array {
1292
    public static function get_nearest_editable_subcategory_provider(): array {
1293
        return [
1293
        return [
1294
            'Hidden main category for manager. Checking create and manage' => [
1294
            'Hidden main category for manager. Checking create and manage' => [
1295
                0,
1295
                0,
1296
                false,
1296
                false,
1297
                'manager',
1297
                'manager',
Línea 1397... Línea 1397...
1397
 
1397
 
1398
        // Configure a filter to apply to all content and headings.
1398
        // Configure a filter to apply to all content and headings.
1399
        filter_set_global_state('multilang', TEXTFILTER_ON);
1399
        filter_set_global_state('multilang', TEXTFILTER_ON);
Línea -... Línea 1400...
-
 
1400
        filter_set_applies_to_strings('multilang', true);
-
 
1401
 
-
 
1402
        // First test with the performance setting off.
1400
        filter_set_applies_to_strings('multilang', true);
1403
        set_config('filternavigationwithsystemcontext', 0);
1401
 
1404
 
Línea 1402... Línea 1405...
1402
        $perf = $filtermanager->get_performance_summary();
1405
        $perf = $filtermanager->get_performance_summary();
1403
        $this->assertEquals(0, $perf[0]['contextswithfilters']);
1406
        $this->assertEquals(0, $perf[0]['contextswithfilters']);