It would be great to return the saving status for user entity type. Currently the UserStorage::save() method returns NULL.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jeqq’s picture

Status: Active » Needs review
jeqq’s picture

Issue summary: View changes
dawehner’s picture

Do you think its worth writing some test for it?

The fix looks perfect.

jeqq’s picture

Added a simple test for this.

dixon_’s picture

Status: Needs review » Needs work
+++ b/core/modules/user/src/Tests/UserSaveStatusTest.php
@@ -0,0 +1,41 @@
+class UserSaveStatusTest extends WebTestBase {

I believe we can use KernelTestBase for this test instead. That way the test would run a lot faster. You basically just have to install the entity schema in the setUp() method (with \Drupal\simpletest\KernelTestBase::installEntitySchema()).

jeqq’s picture

Status: Needs work » Needs review
FileSize
1.88 KB

Thanks @dixon_! Used KernelTestBase instead of WebTestBase.

m4olivei’s picture

Patch looks good to me. Makes sense, applies clean, new test ran locally passed.

dixon_’s picture

Status: Needs review » Reviewed & tested by the community

The new patch looks good. Simple and straight forward fix.

alexpott’s picture

Category: Task » Bug report
Status: Reviewed & tested by the community » Fixed

This issue is a normal bug fix, and doesn't include any disruptive changes, so it is allowed per https://www.drupal.org/core/beta-changes. Committed 782df90 and pushed to 8.0.x. Thanks!

  • alexpott committed 782df90 on 8.0.x
    Issue #2462265 by jeqq: Return saving status when saving user entities
    

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.