Search moodle.org's
Developer Documentation

See Release Notes
Long Term Support Release

  • Bug fixes for general core bugs in 4.1.x will end 13 November 2023 (12 months).
  • Bug fixes for security issues in 4.1.x will end 10 November 2025 (36 months).
  • PHP version: minimum PHP 7.4.0 Note: minimum PHP version has increased since Moodle 4.0. PHP 8.0.x is supported too.

Class: model_test  - X-Ref

Unit tests for the model.

setUp()   X-Ref
No description

test_enable()   X-Ref
No description

test_create()   X-Ref
No description

test_delete()   X-Ref
test_delete


test_clear()   X-Ref
test_clear


test_clear_static()   X-Ref
Test behaviour of {\core_analytics\model::clear()} for static models.


test_model_manager()   X-Ref
No description

test_output_dir()   X-Ref
No description

test_unique_id()   X-Ref
No description

test_exists()   X-Ref
test_exists

return: void

test_model_timelimit()   X-Ref
test_model_timelimit

return: null

test_model_config_get_class_component()   X-Ref
Test model_config::get_class_component.


test_import_model_config()   X-Ref
Test that import_model import models' configurations.


test_can_export_configuration()   X-Ref
Test can export configuration


test_export_config()   X-Ref
Test export_config


test_inplace_editable_name()   X-Ref
Test the implementation of {@link \core_analytics\model::inplace_editable_name()}.


test_get_name_and_rename()   X-Ref
Test how the models present themselves in the UI and that they can be renamed.


test_potential_timesplittings()   X-Ref
Tests model::get_potential_timesplittings()


test_get_samples()   X-Ref
Tests model::get_samples()

return: null

add_fake_log()   X-Ref
Generates a model log record.


Class: testable_model  - X-Ref

Testable version to change methods' visibility.

init_analyser($options = array()   X-Ref
init_analyser

param: array $options
return: void