openequella / moodle-mod_openEQUELLA

Moodle module for integration with openEQUELLA
https://openequella.github.io/moodle-mod_openEQUELLA/
GNU General Public License v3.0
6 stars 16 forks source link

Mdl4.5 core_external\external_api_test units failing because of mod_equella functions in externallib.php #99

Open aneno-m-e opened 6 days ago

aneno-m-e commented 6 days ago

Running core_external\external_api_test::test_all_external_info unit test in isolation results in the following output:

There were 2 errors:

1) core_external\external_api_test::test_all_external_info with data set "equella_find_all_usage" (stdClass Object (...))
Unexpected debugging() call detected.
Debugging: Invalid $required parameter value: '' .
                It must be either VALUE_DEFAULT, VALUE_REQUIRED, or VALUE_OPTIONAL

2) core_external\external_api_test::test_all_external_info with data set "equella_find_usage_for_item" (stdClass Object (...))
Unexpected debugging() call detected.
Debugging: Invalid $required parameter value: '' .
                It must be either VALUE_DEFAULT, VALUE_REQUIRED, or VALUE_OPTIONAL

The issue seems to come from L137 and L165 of the externallib.php file.

Running:

usqfowlerj commented 6 days ago

The solution I've been using can be found in this branch.