The Needs Review Queue Bot โ tested this issue. It either no longer applies to Drupal core, or fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".
Apart from a re-roll or rebase, this issue may need more work to address feedback in the issue or MR comments. To progress an issue, incorporate this feedback as part of the process of updating the issue. This helps other contributors to know what is outstanding.
Consult the Drupal Contributor Guide โ to find step-by-step guides for working with issues.
- ๐จ๐ฆCanada Liam Morland Ontario, CA ๐จ๐ฆ
liam morland โ made their first commit to this issueโs fork.
- ๐จ๐ฆCanada Liam Morland Ontario, CA ๐จ๐ฆ
If the value is NULL, the automatic message will result in this error:
Argument #2 ($message) must be of type string, Drupal\Component\Render\FormattableMarkup
- Merge request !9344Issue #3043127: Document, type-declare, and accept a null value for $message in FileFieldTestBase::assertFileEntryNotExists() โ (Closed) created by Liam Morland
- Status changed to Needs review
11 months ago 1:01am 28 August 2024 - Status changed to Needs work
11 months ago 1:47pm 29 August 2024 - ๐บ๐ธUnited States smustgrave
Can issue summary be updated to use standard template.
Pretty sure javascript is a random failure.
- Status changed to Needs review
11 months ago 1:52pm 29 August 2024 - ๐บ๐ธUnited States smustgrave
Shouldn't the default be '' and don't need to typecast?
- ๐จ๐ฆCanada Liam Morland Ontario, CA ๐จ๐ฆ
Other ones have NULL as the default. The cast is needed anyway because of the error I mentioned in #16.
- Status changed to RTBC
11 months ago 6:25pm 10 September 2024 - ๐บ๐ธUnited States smustgrave
Gotcha,
Change seems small then so don't mind marking.
- Status changed to Needs work
22 days ago 9:45am 12 July 2025 - First commit to issue fork.
- ๐ฎ๐ณIndia mohit_aghera Rajkot
I'm setting back to RTBC since there is just one change (setting default value to param) in the test file now.
MR is updated with latest 11.x
Tests are green as well. - ๐บ๐ธUnited States xjm
The method is missing its parameter documentation, which does not help the situation. Given that we're changing the allowed values of the assertion method, I think it's also in scope to add parameter docs.
Since the current version is only broadening the allowed values of the method, it's pretty BC. That said, since we're talking of typehints, I think we can also expand the scope to add signature typehints to the assertion, which is an allowable BC break for test-only code. I checked contrib usages and overrides of this assertion, and there's only one contrib module in a non-D7 test: MinisiteTestBase.
Thanks everyone!
- ๐บ๐ธUnited States xjm
Sorry, I should have provided the reference to the BC policy regarding test code โ . In this case, since it's a method on a base class, it's borderline, but as a release manager I have discretion to allow internal BC breaks in certain cases like this one. :) Thanks!
- ๐ฎ๐ณIndia mohit_aghera Rajkot
Thanks for clarifying and updating the issue.
I've made necessary changes to the assertion call.
MR is green now. - ๐จ๐ฆCanada Liam Morland Ontario, CA ๐จ๐ฆ
I have rebased this. Is there a reason this does not also add type declarations to the other methods in that file?
- ๐บ๐ธUnited States xjm
@liam morland That could be done elsewhere -- and there are meta issues to address missing typehints in core generally -- but it is out of scope for this issue, which is just about the one specific method. Thanks!
- ๐บ๐ธUnited States xjm
Committed to 11.x despite the BC break, based on my assessment in #27. I also backported it to 11.2.x in accordance with ๐ [policy, no patch] Update allowed changes to current practice for backport of Test API changes Active .
Thanks everyone!