Problem/Motivation
This issue enables #2807237: PHPUnit initiative
This issue comes from deciding scope for #2803621: Break BrowserTestBase & children dependency on Simpletest, deprecate stub BC traits
If you search core/tests
for \simpletest\
, you discover that there are 10 files which depend on the simpletest module being installed (or at least autoloadable).
This is bad because we want to get rid of dependencies on simpletest so we can get rid of simpletest.
These fall into two categories:
1) Test traits which are used by PHPUnit-based tests (including KernelTestBase
and BrowserTestBase
), but are declared within the simpletest module.
The solution to this problem is confused by the fact that there are two non-simpletest locations for test traits: core/lib/Drupal/Core/Test
and core/tests/Drupal/Tests
. To further confuse matters, core/tests/Drupal/Tests
has a Traits
subdirectory, which seems to be in use for some traits, but not for others.
2) TestSuiteBase
which uses Drupal\simpletest\TestDiscovery
.
TestDiscovery
could be moved to a different directory, but it is also a service used by core, and should perhaps not be available when the simpletest module is not installed. #2863055: Move TestDiscovery out of simpletest module, minimize dependencies
Proposed resolution
Figure out where to move stuff.
Remaining tasks
Come up with rules about which directories are for traits.
Comments
Comment #2
Mile23Added a related for minimizing dependencies in
TestDiscovery
: #2863055: Move TestDiscovery out of simpletest module, minimize dependenciesComment #3
Mile23Comment #4
michielnugter CreditAttribution: michielnugter as a volunteer and at Synetic commentedComment #5
Mile23Comment #7
Mile23New child: #2907169: Break KernelTestBase dependency on Simpletest, deprecate stub BC traits
Comment #9
Mile23Added child #2942314: Move JavascriptGetDrupalSettingsTest, BrowserWithJavascriptTest out of simpletest module
Comment #11
Mile23New child: #2996789: Deprecate Drupal\field\Tests\EntityReference\EntityReferenceTestTrait
Comment #12
jibranIs this done now?
Comment #13
Mile23See child issues, and especially #2866082: [Plan] Roadmap for Simpletest
Comment #15
Mile23As per the issue summary, searching core/tests/ for \simpletest\ results in either docblock or test data results.
All the child issues are closed.
Marking this as fixed.