Exemplo n.º 1
0
 public function testProcess()
 {
     $user = $this->getMockUser();
     $mail = new CM_Mail_ExampleMailable($user);
     $site = CM_Site_Abstract::factory();
     $render = new CM_Frontend_Render(new CM_Frontend_Environment($site));
     $request = new CM_Http_Request_Get($render->getUrlEmailTracking($mail), ['host' => $site->getHost()]);
     $response = CM_Http_Response_EmailTracking::createFromRequest($request, $site, $this->getServiceManager());
     $response->process();
     $actionList = new CM_Paging_Action_User($user, CM_Action_Email::getTypeStatic(), CM_Action_Abstract::getVerbByVerbName(CM_Action_Abstract::VIEW));
     $this->assertSame(1, $actionList->getCount());
 }
Exemplo n.º 2
0
 /**
  * @param string            $verbName
  * @param CM_Model_User|int $actor
  */
 public function __construct($verbName, $actor)
 {
     $this->setActor($actor);
     $this->_verb = CM_Action_Abstract::getVerbByVerbName($verbName);
 }