コード例 #1
0
 /**
  * @test
  */
 public function testGetAuditEntryFieldClass()
 {
     $user = $this->getDiamanteUser();
     $this->auditEntityMapper->addAuditEntryFieldClass('Diamante\\UserBundle\\Entity\\DiamanteUser', 'Diamante\\DeskBundle\\Entity\\AuditField');
     $result = $this->auditEntityMapper->getAuditEntryFieldClass($user);
     $this->assertEquals('Diamante\\DeskBundle\\Entity\\AuditField', $result);
 }
コード例 #2
0
 protected function setUp()
 {
     MockAnnotations::init($this);
     $this->auditEntityMapper->addAuditEntryClass('Diamante\\UserBundle\\Entity\\DiamanteUser', 'Diamante\\DeskBundle\\Entity\\Audit');
     $this->auditEntityMapper->addAuditEntryFieldClass('Diamante\\UserBundle\\Entity\\DiamanteUser', 'Diamante\\DeskBundle\\Entity\\AuditField');
     $this->container->expects($this->any())->method('get')->will($this->returnValue($this->oroAuditEntityMapper))->with($this->equalTo('oro_dataaudit.loggable.audit_entity_mapper'));
     $this->loggableManager = new LoggableManager('Oro\\Bundle\\DataAuditBundle\\Entity\\Audit', 'Oro\\Bundle\\DataAuditBundle\\Entity\\AuditField', $this->provider, $this->securityContextLink, $this->auditEntityMapper, $this->container);
 }