As far as now all them have correct privacy level2 namespace:
- Move them to "privacy" subdir.
- Rename the files to "provider_test.php", this includes old
privacy_test.php and privacy_provider_test.php files
- Rename the testcase to provider_test too (to match file name)
Also, change some relative paths and comments to point to new
locations.
All privacy_test and privacy_provider_test classes:
- Namespaced with component\privacy.
- Fixed incorrect use statements with leading backslash.
- Changed code to point to global scope when needed.
- Renamed a few files to make all be privacy_test or privacy_provider_test.php
- All them passing individually.
- Complete runs passing too.
These are the only cases 100% safe to apply the renaming of the
testcase class names to match the file names.
All other cases are not safe, because they are missing namespace
and may enter into name conflicts. Adding namespaces is not as
simple as imagined because it implies to, also, add a good number
of modifications to core. See the issue for more details.
AMOS BEGIN
MOV [completionpass,mod_quiz],[completionpassgrade,core_completion]
MOV [completionpassdesc,mod_quiz],[completionpassgrade_desc,core_completion]
MOV [completionpass_help,mod_quiz],[completionpassgrade_help,core_completion]
AMOS END
- Modified SQL in get_data() to get the activity completion of all course modules without calling get_fast_modinfo() to reduce the DB queries.
- Building activity completion cache for the whole course in one time instead of building the cache for each course module by passing $wholecourse = true to get_data()
This adds the requirement for activities supporting custom completion to
specify the order all completion conditions should be displayed for that
activity. It also implements the sorting that takes place.
* When completion tracking is not enabled for the course, it does not
make sense for the course's showcompletionconditions setting to
be set according to the default value indicated by the
"moodlecourse | showcompletionconditions" admin setting. Setting
showcompletionconditions as enabled when completion tracking is disabled
makes even less sense. So in such a case, we should not be setting a
default value for showcompletionconditions and allow it to be null.
* When the course is edited and completion tracking is enabled, this
also would set the "Show completion conditions" field to default to the
value set in the "moodlecourse | showcompletionconditions" admin
setting.
This commits adds a fallback for plugins which does not have
custom_completion implementation.
For those cases, it will search for {modulename}_get_completion_state
callback in the plugin and call get_overall_completion() method in
cm_completion_details class to get the overall completion state for
a course module and user.
* *_get_completion_state() callback functions have been deprecated and
should no longer be used. Plugins that define custom completion rules
must implement the mod_[modname]\completion\custom_completion class that
extends the \core_completion\activity_custom_completion base class.
* activity_completion_condition_displayed_as()
- Shows the status of an automatic completion condition for a given
activity
* activity_should_have_the_completion_condition()
- Checks that the activity displays the given completion condition
* manual_completion_button_displayed_as()
- Shows the status of the manual completion button for a given
activity
* the_manual_completion_button_for_activity_should_be_disabled()
- Checks that the manual completion button for the given activity is
disabled.
* there_should_be_no_completion_for_activity()
- Checks that the activity does not show completion information
* toggle_the_manual_completion_state()
- Toggles the manual completion button's state for a given activity
* overridden_manual_completion_button_displayed_as()
- Checks the manual completion state of an activity.
* overridden_activity_completion_condition_displayed_as()
- Checks if the activity with specified name is maked as complete.