コード例 #1
0
ファイル: Role.php プロジェクト: netzmacht/workflow
 /**
  * Consider if role equals to another role.
  *
  * @param Role $role Role to compare with.
  *
  * @return bool
  */
 public function equals(Role $role)
 {
     return $this->getFullName() == $role->getFullName();
 }
コード例 #2
0
ファイル: RoleSpec.php プロジェクト: netzmacht/workflow
 function it_does_not_equal_to_different_role(Role $role)
 {
     $role->getFullName()->willReturn('other_role');
     $this->equals($role);
 }