Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
D
drupal
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Custom Issue Tracker
Custom Issue Tracker
Labels
Merge Requests
229
Merge Requests
229
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Analytics
Analytics
Code Review
Insights
Issue
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
project
drupal
Commits
0e4742c5
Commit
0e4742c5
authored
Jul 27, 2012
by
webchick
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue
#1503224
by catch, sun, chx, bojanz, tim.plunkett: Cleanup module_list().
parent
f82ad874
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
8 additions
and
7 deletions
+8
-7
core/includes/install.inc
core/includes/install.inc
+1
-1
core/includes/schema.inc
core/includes/schema.inc
+1
-1
core/modules/simpletest/lib/Drupal/simpletest/WebTestBase.php
.../modules/simpletest/lib/Drupal/simpletest/WebTestBase.php
+1
-1
core/modules/system/lib/Drupal/system/Tests/Module/ModuleTestBase.php
.../system/lib/Drupal/system/Tests/Module/ModuleTestBase.php
+1
-1
core/modules/system/lib/Drupal/system/Tests/System/MainContentFallbackTest.php
...ib/Drupal/system/Tests/System/MainContentFallbackTest.php
+2
-2
core/modules/system/lib/Drupal/system/Tests/Upgrade/UpgradePathTestBase.php
...m/lib/Drupal/system/Tests/Upgrade/UpgradePathTestBase.php
+2
-1
No files found.
core/includes/install.inc
View file @
0e4742c5
...
...
@@ -380,7 +380,7 @@ function drupal_install_system() {
// Clear out module list and hook implementation statics before calling
// system_rebuild_theme_data().
drupal_static_reset
(
'system_list'
);
system_list_reset
(
);
module_list_reset
();
module_implements_reset
();
...
...
core/includes/schema.inc
View file @
0e4742c5
...
...
@@ -73,7 +73,7 @@ function drupal_get_complete_schema($rebuild = FALSE) {
// we force the system_list() static cache to be refreshed to ensure
// that it contains the complete list of modules before we go on to call
// module_load_all_includes().
drupal_static_reset
(
'system_list'
);
system_list_reset
(
);
module_load_all_includes
(
'install'
);
}
...
...
core/modules/simpletest/lib/Drupal/simpletest/WebTestBase.php
View file @
0e4742c5
...
...
@@ -789,7 +789,7 @@ protected function tearDown() {
// Reload module list and implementations to ensure that test module hooks
// aren't called after tests.
drupal_static_reset
(
'system_list'
);
system_list_reset
(
);
module_list_reset
();
module_implements_reset
();
...
...
core/modules/system/lib/Drupal/system/Tests/Module/ModuleTestBase.php
View file @
0e4742c5
...
...
@@ -132,7 +132,7 @@ function assertNoModuleConfig($module) {
* Expected module state.
*/
function
assertModules
(
array
$modules
,
$enabled
)
{
drupal_static_reset
(
'system_list'
);
system_list_reset
(
);
foreach
(
$modules
as
$module
)
{
if
(
$enabled
)
{
$message
=
'Module "@module" is enabled.'
;
...
...
core/modules/system/lib/Drupal/system/Tests/System/MainContentFallbackTest.php
View file @
0e4742c5
...
...
@@ -48,7 +48,7 @@ function testMainContentFallback() {
$edit
[
'modules[Core][block][enable]'
]
=
FALSE
;
$this
->
drupalPost
(
'admin/modules'
,
$edit
,
t
(
'Save configuration'
));
$this
->
assertText
(
t
(
'The configuration options have been saved.'
),
t
(
'Modules status has been updated.'
));
drupal_static_reset
(
'system_list'
);
system_list_reset
(
);
$this
->
assertFalse
(
module_exists
(
'block'
),
t
(
'Block module disabled.'
));
// At this point, no region is filled and fallback should be triggered.
...
...
@@ -82,7 +82,7 @@ function testMainContentFallback() {
$edit
[
'modules[Core][block][enable]'
]
=
'block'
;
$this
->
drupalPost
(
'admin/modules'
,
$edit
,
t
(
'Save configuration'
));
$this
->
assertText
(
t
(
'The configuration options have been saved.'
),
t
(
'Modules status has been updated.'
));
drupal_static_reset
(
'system_list'
);
system_list_reset
(
);
$this
->
assertTrue
(
module_exists
(
'block'
),
t
(
'Block module re-enabled.'
));
}
}
core/modules/system/lib/Drupal/system/Tests/Upgrade/UpgradePathTestBase.php
View file @
0e4742c5
...
...
@@ -253,7 +253,8 @@ protected function performUpgrade($register_errors = TRUE) {
// Reload module list. For modules that are enabled in the test database,
// but not on the test client, we need to load the code here.
$new_modules
=
array_diff
(
module_list
(
TRUE
),
$this
->
loadedModules
);
system_list_reset
();
$new_modules
=
array_diff
(
module_list
(),
$this
->
loadedModules
);
foreach
(
$new_modules
as
$module
)
{
drupal_load
(
'module'
,
$module
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment