anthology-ally / moodle-tool_ally

2 stars 18 forks source link

sha1() error when running Behat tests with PHP 8.1 #93

Closed opitz closed 5 months ago

opitz commented 9 months ago

When - for example - running this core test admin/tool/uploadcourse/tests/behat/create.feature the following error is thrown when running tool_ally in a vanilla MOODLE_403_STABLE with PHP 8.1:

001 Scenario: Validation of role for uploaded courses # /var/www/html/admin/tool/uploadcourse/tests/behat/create.feature:110
      When I click on "Upload courses" "button"       # /var/www/html/admin/tool/uploadcourse/tests/behat/create.feature:124
        debugging() message/s found:
        Exception encountered in event observer '\tool_ally\event_handlers::course_created': Unknown error type: sha1(): Passing null to parameter #1 ($string) of type string is deprecated in /var/www/html/admin/tool/ally/classes/models/component_content.php on line 67