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.
Problem/Motivation
As this issue #2737719: EntityResource: Provide comprehensive test coverage: for every entity type, every format, every method has added the test coverage for the User entity with all available formats.
Proposed resolution
Remaining tasks
User interface changes
None.
API changes
None.
Data model changes
None.
Comments
Comment #2
naveenvalechaDuring the conversion of #2870465: Convert web tests to browser tests for user module it looks that there's already the enough test coverage available in the core for the user entity. Does we really needs the
\Drupal\user\Tests\RestRegisterUserTest
?Comment #3
dawehnerThis issue is a bit weird.
RestRegisterUserTest
tests /user/register, which is a different resource than adding a user via REST. Registering a user is something different.Comment #4
Wim LeersThey're very very different indeed.
\Drupal\Tests\rest\Functional\EntityResource\User\UserResourceTestBase
tests\Drupal\rest\Plugin\rest\resource\EntityResource
for the\Drupal\user\Entity\User
entity type.\Drupal\user\Tests\RestRegisterUserTest
tests\Drupal\user\Plugin\rest\resource\UserRegistrationResource
Comment #5
Wim LeersComment #6
naveenvalechaThanks, Wim!
I asked this because the depreciation notice on the class states to use the EntityResourceTestBase & ResourceTestBase instead and we have the enough EntityResource test coverage for the user entity.
#3,
yup
//Naveen