Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
AssertLegacyTrait::assertPattern() is deprecated in drupal:8.2.0 and is removed from drupal:10.0.0. Use $this->assertSession()->responseMatches() instead. See https://www.drupal.org/node/3129738
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
Comment | File | Size | Author |
---|---|---|---|
#19 | 3139436-19.patch | 25.87 KB | jungle |
#19 | raw-interdiff-10-19.txt | 1.91 KB | jungle |
#10 | interdiff_8-10.txt | 828 bytes | mondrake |
#10 | 3139436-10.patch | 25.83 KB | mondrake |
Comments
Comment #2
jungleAdding the "Deprecated assertions" tag to add this into the kanban board https://contribkanban.com/board/Deprecatedassertions
Comment #3
mondrakeThe current calls to
assertPattern
in functional tests still have a message passed in, even if the AssertLegacyTrait::assertPattern() does not tak that in. We need to remove the messages from the calls and inline them as comments where appropriate before doing the conversion.Comment #4
mondrakeFiled #3142749: AssertLegacyTrait::assertPattern() calls in functional tests still have a message passed in.
Comment #5
mondrakeBlocker went in, unpostponing
Comment #6
mondrakeFirst patch. Needs deprecation tests.
Comment #7
mondrakeComment #8
mondrakeAdded deprecation test.
Comment #10
mondrakeTitle is not in the page...
Comment #11
mondrakeReady for review.
Comment #12
jungleDeprecated AssertLegacyTrait::assertPattern() gets tested
Removed from the list.
It's ready to go to me, Thanks @mondrake!
Comment #13
dwwcore/tests/Drupal/KernelTests/AssertContentTrait.php has a non-deprecated version of
assertPattern()
. What's up, doc?Thanks/sorry,
-Derek
Comment #14
mondrake#13 see #3027952-50: [Plan] Remove the usage of deprecated methods in tests.
Comment #15
dwwRe #14: thanks for clarifying.
#12 is an excellent RTBC. ;) That's everything I just checked and agree with all points.
One might complain that the summary is a bit bare, but this is part of a bigger effort and it says all it needs to say. ;)
Thanks/sorry,
-Derek
Comment #17
dwwRandom fail. Requeued.
Comment #18
catchNeeds a re-roll.
Comment #19
jungleRejected:
Comment #20
dwwrawdiff looks good. Only context changed, nothing in the code.
Confirming #19 applies cleanly to 9.1.x branch.
Assuming the bot is happy, this is RTBC again.
Thanks,
-Derek
Comment #22
catchCommitted 49d9b09 and pushed to 9.1.x. Thanks!