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.
See #2848161: [meta] Replace calls to deprecated db_*() wrappers
Problem/Motivation
Using the RegressionTest class for deprecation tests is confusing. In the parent issue the testDbTableExist
method has been changed to track deprecation, which means that it will be dropped in 9.0 when the db* wrappers will be removed from code. But that test is pre-existing and should not be dropped.
Proposed resolution
Add a DatabaseLegacyTest
class for deprecation tests only, and move the tests already coded there.
Remaining tasks
User interface changes
API changes
Data model changes
Comment | File | Size | Author |
---|---|---|---|
#4 | interdiff_2-4.txt | 495 bytes | mondrake |
#4 | 2991542-4.patch | 4.11 KB | mondrake |
Comments
Comment #2
mondrakeComment #3
volegerThis is redundant code.
DatabaseTestBase
already has database connection injected intoconnection
property.Comment #4
mondrakeIndeed, thank you @voleger
Comment #5
volegerTests are "green". +1 for RTBC
And let's continue with replacing deprecated db_* functions.
Comment #6
alexpottCommitted and pushed 3f44f5bbcb to 8.7.x and c4c573303d to 8.6.x. Thanks!
Comment #7
alexpottBackported to 8.6.x since this is a test-only change.