예제 #1
0
 public function test_has_role_when_when_role_assigned()
 {
     $this->user->setRoles([$this->admin]);
     $this->assertTrue($this->user->hasRole($this->admin));
 }
예제 #2
0
 public function test_has_all_role_when_role_assigned()
 {
     $this->user->setRoles([$this->admin, $this->extraRole1, $this->extraRole2]);
     $this->assertTrue($this->user->hasRole([$this->admin, $this->extraRole1, $this->extraRole2], true));
 }