Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix warning - undefined property behat_prefix #208

Merged
merged 1 commit into from
Mar 20, 2024

Conversation

AnupamaSarjoshi
Copy link
Contributor

Hi Richard,

We see some of the warnings with PHP8.2
Coderunner version 2024031500
release '5.3.1'.

Noticed the below warnings when we edit the Coderuner questions:

Warning: Undefined property: stdClass::$behat_prefix in /var/www/html/moodle/question/type/coderunner/classes/sandbox.php on line 39
Warning: Undefined property: stdClass::$behat_prefix in /var/www/html/moodle/question/type/coderunner/edit_coderunner_form.php on line 253

Could you please review the fix and suggest if it looks good?

Thanks,
Anupama

@trampgeek trampgeek merged commit b1f2d7c into trampgeek:master Mar 20, 2024
5 checks passed
@trampgeek
Copy link
Owner

trampgeek commented Mar 20, 2024

Many thanks Anupama. I had my own fixes in the pipeline but I prefer yours. Though I will shortly do another push to remove the hack to sandbox.php that forces the loading of the test config when testing. I'm following Tim's proposal and have updated all behat features to explicitly require the test sandbox config, though I do think it's clumsy to have to do that for all tests. It's pretty much like having to start all behat code with a function like "if we're running behat ... :" !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants