コード例 #1
0
 /**
  * @covers Core\Entity\AbsenceReason::refreshTimeStamps
  */
 public function testRefreshTimeStamps()
 {
     $absenceReason = new AbsenceReason($this->mockEntityManager);
     $absenceReason->refreshTimeStamps();
     $createdAt = $absenceReason->getCreatedAt();
     $this->assertNotNull($createdAt);
     $this->assertNull($absenceReason->getUpdatedAt());
     $absenceReason->refreshTimeStamps();
     $updatedAt = $absenceReason->getUpdatedAt();
     $this->assertNotNull($updatedAt);
     $this->assertEquals($createdAt, $absenceReason->getCreatedAt());
 }
コード例 #2
0
 /**
  * {@inheritDoc}
  */
 public function getUpdatedAt()
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'getUpdatedAt', array());
     return parent::getUpdatedAt();
 }