Closed (fixed)
Project:
Drupal core
Version:
11.x-dev
Component:
phpunit
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
5 May 2023 at 07:54 UTC
Updated:
10 Sep 2023 at 05:03 UTC
Jump to comment: Most recent
Maybe [we can deprecate]
RandomGeneratorTrait::randomStringValidate()which is just a callback that is no longer called since the entire implementation moved to the new static methods.
@mondrake in #3358186-5: [META] Deprecate non-static random generation methods from RandomGeneratorTrait
Deprecated in drupal:10.2.0 and is removed from drupal:11.0.0.
Use \Drupal\TestTools\Random::stringValidate() instead.
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
spokjePostponing on #3358375: Fix incorrect usage of randomStringValidate in \Drupal\Tests\jsonapi\Kernel\Normalizer\JsonApiDocumentTopLevelNormalizerTest::setUp
Comment #3
spokjeComment #4
spokjeComment #5
spokjeComment #8
mondrakeBlocker’s in now.
Comment #9
spokjeRebased MR on
11.x, changed deprecation message in IS, MR and CR.Comment #10
spokjeThanks for the headsup @mondrake.
Comment #11
spokjeComment #12
spokjeWhoops, thoght this was already RTBC at some point...
Comment #13
mondrakeI suppose we need a deprecation test here...
Comment #14
spokjeAlso thought so, but appearantly, that ran out of fashion on Traits?
No deprecation tests that I could find on, for example:
- this
\Drupal\views\Entity\Render\EntityTranslationRenderTrait::getEntityTranslation- this
\Drupal\Tests\book\Functional\BookTestTrait::generateOutlinePatternSo, unless my search failed, I'm not bothering with that ATM.
Comment #15
mondrakeLet's see feedback from committers then.
Comment #16
spokje* runs to the popcorn store *
Comment #20
catchYes if the deprecation test would only test that we call trigger_error() with correct string, then it's fine not to bother with a deprecation test. If there's actual bc logic (outside trivial stuff in a constructor) it's a bit different.
Committed 4df80c6 and pushed to 11.x. Thanks!
Comment #23
quietone commentedPublished change record.