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

update deprecated and broken tests #53

Open
wants to merge 2 commits into
base: MOODLE_39_STABLE
Choose a base branch
from

Conversation

jay-oswald
Copy link

Updating unit tests. assertContains does not work with the string, and is deprecated, replaced with assertStringContainsString and the not equivalents. Same with regex tests, also updated and replaced, as assertRegExp is deprecated and getting removed from phpunit 10

Tested with php 8.1 and moodle 4.1, however moodle 3.9 uses phpunit 7.5.

assertStringContainsString existed in 7.5, however assertMatchesRegularExpression had not been added yet.

Happy to re-do the PR without the regex if you want to merge into 3.9, or could create a new 4.1 branch?

@jay-oswald
Copy link
Author

I decided to just remove the assertRegExp fix, as this means it stays 3.9 compatible, changing regex can be done on a 4.1+ version

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.

1 participant