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
The same as #2970026: Fix "Passing a Session object to the ExpectationException constructor is deprecated as of Mink 1.7. Pass the driver instead." but for the exception class ElementNotFoundException
extending from ExpectationException
.
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Comment | File | Size | Author |
---|---|---|---|
#11 | 3005352-code-standard-errors.png | 12.71 KB | rensingh99 |
#11 | interdiff.txt | 817 bytes | rensingh99 |
#11 | 3005352-11.patch | 2.12 KB | rensingh99 |
Comments
Comment #2
hchonovComment #3
hchonovComment #5
marcel66 CreditAttribution: marcel66 commentedYou are right, but the patch needs to be adjusted for 8.8.x.
Comment #6
marcel66 CreditAttribution: marcel66 commentedComment #7
hchonov@marcel66, the patch applies cleanly on 8.8.x.
Comment #8
oknateRerolling
Comment #10
rensingh99 CreditAttribution: rensingh99 at Red Crackle commentedComment #11
rensingh99 CreditAttribution: rensingh99 at Red Crackle commentedHi,
I have reviewed patch #8 and I got two errors which are not as per Drupal coding standard.
I have fixed one error and uploaded the patch.
The other error is related to function names which is being used in multiple test files. So, I did not change it.
This fix might be beyond the scope of this task.
Thank you
Ren
Comment #12
rensingh99 CreditAttribution: rensingh99 at Red Crackle commentedComment #13
hchonovThe change from #11 is not related to the changes in the current patch, but changes only old code unrelated to the issue. Changes not in scope should be avoided.
Comment #14
alexpottCommitted and pushed 03ef2f6238 to 9.0.x and 18fcc6329c to 8.9.x. Thanks!
Thanks for fixing this. This has bugged me for ages! Error messages produce further error messages make it hard to understand test fails. I've committed #8 as @hchonov is correct those changes are out-of-scope.
I've not credited @rensingh99 for filing an out-of-scope patch. @rensingh99 Thank you for your work on cleaning up Drupal core's code style!
In order to fix core coding standards in a maintainable way, all our coding standards issues should be done on a per-rule basis across all of core, rather than fixing standards in individual modules or files. We should also separate fixes where we need to write new documentation from fixes where we need to correct existing standards. This all should be done as part of #2571965: [meta] Fix PHP coding standards in core. A good place to start is the child issues of #2572645: [Meta] Fix 'Drupal.Commenting.FunctionComment' coding standard.
For background information on why we usually will not commit coding standards fixes that aren't scoped in that way, see the core issue scope guidelines, especially the note about coding standards cleanups. That document also includes numerous suggestions for scoping issues including documentation coding standards cleanups.
Contributing to the overall plan above will help ensure that your fixes for core's coding standards remain in core the long term.
Comment #17
geasePatch #8 still applies to 8.8.x.
Comment #18
alexpott@gease both @catch and I use the "patch to be ported" status to separate these from the other rtbc's that are yet to be committed to any branch. It makes it less likely to be missed.
Comment #19
hchonov@alexpott, if that's your workflow then the corresponding documentation should be updated to reflect it - https://www.drupal.org/contributor-tasks/backport
Comment #20
alexpottDiscussed with @catch we agreed to backport.