Esempio n. 1
0
 /** @test */
 function it_is_dead_if_no_units_are_alive()
 {
     $unit1 = $this->getMock(Army\Unit\Unit::class);
     $unit2 = $this->getMock(Army\Unit\Unit::class);
     $unit1->method('isDead')->willReturn(true);
     $unit2->method('isDead')->willReturn(true);
     $this->army->add($unit1);
     $this->army->add($unit2);
     $this->assertTrue($this->army->isDead());
 }