Example #1
0
 public function testGetContractNumbers()
 {
     $c1 = $this->getMock('JLM\\ContractBundle\\Model\\ContractInterface');
     $c2 = $this->getMock('JLM\\ContractBundle\\Model\\ContractInterface');
     $c1->expects($this->once())->method('getNumber')->will($this->returnValue('12345'));
     $c2->expects($this->once())->method('getNumber')->will($this->returnValue('6789'));
     $this->entity->addContract($c1);
     $this->entity->addContract($c2);
     $this->assertSame(array('12345', '6789'), $this->entity->getContractNumbers());
 }