示例#1
0
 /**
  * @test
  * @group value
  */
 public function it_can_check_whether_or_not_it_is_of_a_particuler_level()
 {
     $loa = new Loa(Loa::LOA_2, '2');
     $this->assertFalse($loa->isOfLevel(Loa::LOA_1), 'Loa 2 is not of level 1');
     $this->assertTrue($loa->isOfLevel(Loa::LOA_2), 'Loa 2 is of level 2');
     $this->assertFalse($loa->isOfLevel(Loa::LOA_3), 'Loa 2 is not of level 3');
 }
 /**
  * @param Loa $loa
  * @return bool
  */
 public function isSatisfiedBy(Loa $loa)
 {
     return $loa->levelIsHigherOrEqualTo($this->getLevel());
 }
示例#3
0
 /**
  * @param Loa $loa
  * @return bool
  */
 public function canSatisfyLoa(Loa $loa)
 {
     return $loa->levelIsLowerOrEqualTo($this->level);
 }