Updating the "activated" key

parent 88c7d35c
...@@ -299,7 +299,7 @@ class SentinelUserRepositoryTest extends BaseUserTestCase ...@@ -299,7 +299,7 @@ class SentinelUserRepositoryTest extends BaseUserTestCase
'password' => 'demo1234', 'password' => 'demo1234',
], [1]); ], [1]);
$this->user->updateAndSyncRoles($user->id, ['first_name' => 'John', 'last_name' => 'Doe', 'activated' => 1], [2]); $this->user->updateAndSyncRoles($user->id, ['first_name' => 'John', 'last_name' => 'Doe', 'is_activated' => 1], [2]);
$user->refresh(); $user->refresh();
...@@ -319,7 +319,7 @@ class SentinelUserRepositoryTest extends BaseUserTestCase ...@@ -319,7 +319,7 @@ class SentinelUserRepositoryTest extends BaseUserTestCase
], [1]); ], [1]);
Event::fake(); Event::fake();
$this->user->updateAndSyncRoles($user->id, ['first_name' => 'John', 'last_name' => 'Doe', 'activated' => 1], [2]); $this->user->updateAndSyncRoles($user->id, ['first_name' => 'John', 'last_name' => 'Doe', 'is_activated' => 1], [2]);
Event::assertDispatched(UserWasUpdated::class, function ($e) use ($user) { Event::assertDispatched(UserWasUpdated::class, function ($e) use ($user) {
return $e->user->id === $user->id; return $e->user->id === $user->id;
...@@ -342,7 +342,7 @@ class SentinelUserRepositoryTest extends BaseUserTestCase ...@@ -342,7 +342,7 @@ class SentinelUserRepositoryTest extends BaseUserTestCase
'password' => 'demo1234', 'password' => 'demo1234',
], [1]); ], [1]);
$this->user->updateAndSyncRoles($user->id, ['first_name' => 'John', 'last_name' => 'Doe', 'activated' => 1], [1]); $this->user->updateAndSyncRoles($user->id, ['first_name' => 'John', 'last_name' => 'Doe', 'is_activated' => 1], [1]);
$this->assertEquals('Jane', $this->user->find(1)->first_name); $this->assertEquals('Jane', $this->user->find(1)->first_name);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment