/** * @return int */ public function getAgentId() { return $this->agentRef->getAgentId(); }
public function testGetAgentName() { $agentName = "<agentName>"; $this->agentRef->shouldReceive('getAgentName')->once()->withNoArgs()->andReturn($agentName); assertThat($this->agentClearingEvent->getAgentName(), is($agentName)); }
/** * @return array */ protected function createScannerDetectedLicenses($licenseId = 13, $licenseShortname = "licA", $licenseFullName = "License-A") { $licenseRef = new LicenseRef($licenseId, $licenseShortname, $licenseFullName); $agentRef = M::mock(AgentRef::classname()); $scannerEvents = array($licenseId => array(new AgentClearingEvent($licenseRef, $agentRef, self::MATCH_ID, self::PERCENTAGE))); return array($scannerEvents, $licenseRef, $agentRef); }