public function setUp() { $this->player1 = new Player(); $this->player1->setName('Foo'); $this->player2 = new Player(); $this->player2->setName('Bar'); $this->team = new Team($this->player1, $this->player2); }
protected function getPlayer($id, $name) { $player = new Player(); $player->setId($id); $player->setName($name); return $player; }
public function testGetArrayCopy() { $this->player->setId(2); $this->player->setName("Bar"); $this->assertEquals(array('id' => 2, 'name' => 'Bar', 'points' => 1000, 'matchCount' => 0), $this->player->getArrayCopy()); }