Fixed
Project:
Search (from core)
Version:
1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Nov 2026 at 09:38 UTC
Updated:
11 Nov 2026 at 10:27 UTC
Jump to comment: Most recent
Got a warning on a client project when Composer generates the autoloader.
A namespace is wrong in a test class.
root@558f99f33bb9:/app# composer dump-autoload
Generating optimized autoload files
Class Drupal\Tests\search\Nightwatch\Olivero\TestSiteOliveroInstallTestScript located in ./web/core/modules/search/tests/src/Nightwatch/Tests/Olivero/TestSiteOliveroInstallTestScript.php does not comply with psr-4 autoloading standard (rule: Drupal\Tests\search\ => ./web/core/modules/search/tests/src). Skipping.
The project is using the package "fenetikm/autoload-drupal" which allowed to highlight the problem.
The project is currently on Core 11, that's why the path to the search module is still in Core on the message.
For Core fix on 11.x, I have created the issue #3636716: Wrong namespace in a test class.
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 #3
grimreaperNot sure which one is better between fixing the namespace or moving the files one folder up.
Comment #4
xmacinfoTests are failing.
Please document the warning you received on a client's project in the IS.
Comment #5
grimreaperThe failing tests are unrelated to the change proposed in the MR.
IS updated.
Comment #7
xmacinfoOK Florent. You are officially the first committer for the contrib version of Search. MR number 1.
Merci beaucoup.
Comment #9
grimreaperI did not notice the MR number :)
Thanks Jacques :)