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.
Subissue of #1787218: Convert testing variables to state system..
Change the state variables:
front_page_output
image_test_results
path_test_results
simpletest_bootstrap_variable_test
test_module_enable_order
test_verbose_module_hooks
to the state system.
Comment | File | Size | Author |
---|---|---|---|
#6 | 1848058-system_to_state-drupal8-6.patch | 8.93 KB | ACF |
#4 | 1848058-system_to_state-drupal8-4.patch | 9.36 KB | ACF |
#1 | 1848058-system_to_state-drupal8-1.patch | 11.42 KB | ACF |
Comments
Comment #1
ACF CreditAttribution: ACF commentedPatch attached.
Comment #2
ACF CreditAttribution: ACF commentedComment #3
gddWe shouldn't actually convert the variable tests. These are specifically to test the variable system and make no sense if converted to the state system. If the variable system does get removed we'll just delete all these tests. I'll remove these from the meta-issue.
All implementations of state()->get() in this patch need to specify a default by doing something along the lines of
state()->get('system_test.module_enable_order') ?: array()
Don't worry about this because state()->get() already returns NULL when the key doesn't exist.
Comment #4
ACF CreditAttribution: ACF commentedRemoved the changes to variable.test and added the defaults.
Comment #6
ACF CreditAttribution: ACF commentedRemove last link to variable test.
Comment #7
aspilicious CreditAttribution: aspilicious commentedLooks great passes tests
Comment #8
webchickCommitted and pushed to 8.x. Thanks!
Comment #9.0
(not verified) CreditAttribution: commentedadded issue number