Closed (fixed)
Project:
Drupal core
Version:
9.1.x-dev
Component:
phpunit
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
19 Sep 2016 at 14:07 UTC
Updated:
12 Oct 2020 at 10:24 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
catchBefore we remove this, we should trigger E_USER_DEPRECATED in that code block in 8.x
Comment #9
jhedstromPresumably the second parameter should be type-hinted to
arrayin Drupal 9? Also, I thought we could make changes like this to our test infrastructure without deprecating? So we could just type-hint to an array now...Comment #10
jhedstromMaking this change to see what explodes :)
Comment #13
longwaveSpotted the @todo for this, let's revive this and see what happens.
Comment #15
mondrakeComment #16
longwaveFixing failures and improving title.
Comment #18
longwaveMissed a couple.
Comment #19
mondrakeLooks good and will prepare for overall deprecation of drupalPostForm.
Needs a CR (or a portion of the CR deprecating drupalPostForm), deprecation test, and a reroll.
Comment #20
mondrakeComment #21
mondrakeActually, the deprecation message should suggest to use $this->submitForm straight away, if we are to remove deupalPostForm by D10.
Comment #22
longwaveReroll, still needs tests and a CR.
Comment #23
mondrakeAdded this issue to the overall drupalPostForm deprecation CR, https://www.drupal.org/node/3168858
Comment #24
naresh_bavaskarRerolled again #22, still needs tests and a CR
Comment #25
akashkumar07 commentedComment #26
mondrakeThis needs to be adjusted to reflect the URL of the CR, https://www.drupal.org/node/3168858.
We need a simple deprecation test, so to check that when the method is called with NULL for the $edit argument, the deprecation error is actually triggered.
EDIT: also, the deprecation message format is not compliant to the standard format.
Comment #27
sarvjeetsingh commentedUpdated the URL of the CR.
@mondrake, I am not sure how it is not compliant to the standard format, please give more info.
Also, i have found out that the use of UiHelperTrait::drupalPostForm() is deprecated now so shouldn't we include a deprecation message regarding that?
Comment #28
mondrake@sarvjeetsingh the deprecation of UiHelperTrait::drupalPostForm() is not yet live, so let's wait for #3166543: Deprecate UiHelperTrait::drupalPostForm, keep deprecation silenced that adds the that.
Once that is in, the deprecation message could be:
'Calling ' . __METHOD__ . ' with $edit set to NULL is deprecated in drupal:9.1.0 and the method is removed in drupal:10.0.0. Use $this->submitForm() instead. See https://www.drupal.org/node/3168858Comment #29
mondrakeParent is in now. We can work on this now.
Comment #30
sarvjeetsingh commented@mondrake, Thanks for the suggestion. I have changed the deprecation message as per the above suggestion.
please review.
Comment #31
sarvjeetsingh commentedplease ignore the last comment i.e #30. Here is the updated patch.
please review
Thanks!
Comment #32
mondrake#31 looks good but we still need a test.
Comment #33
longwaveAdded a test, added
()to the deprecated method name, removed the @todo for this issue.Comment #34
mondrakeThanks!
Comment #36
catchCommitted a60fbb6 and pushed to 9.1.x. Thanks!