| @@ 118-126 (lines=9) @@ | ||
| 115 | $this->assertEquals($value, $this->comment->getUpdatedAt()); |
|
| 116 | } |
|
| 117 | ||
| 118 | public function testPrePersist() |
|
| 119 | { |
|
| 120 | $this->assertNull($this->comment->getCreatedAt()); |
|
| 121 | ||
| 122 | $this->comment->prePersist(); |
|
| 123 | ||
| 124 | $this->assertInstanceOf('DateTime', $this->comment->getCreatedAt()); |
|
| 125 | $this->assertLessThan(3, $this->comment->getCreatedAt()->diff(new \DateTime())->s); |
|
| 126 | } |
|
| 127 | ||
| 128 | public function testPreUpdate() |
|
| 129 | { |
|
| @@ 128-136 (lines=9) @@ | ||
| 125 | $this->assertLessThan(3, $this->comment->getCreatedAt()->diff(new \DateTime())->s); |
|
| 126 | } |
|
| 127 | ||
| 128 | public function testPreUpdate() |
|
| 129 | { |
|
| 130 | $this->assertNull($this->comment->getUpdatedAt()); |
|
| 131 | ||
| 132 | $this->comment->preUpdate(); |
|
| 133 | ||
| 134 | $this->assertInstanceOf('DateTime', $this->comment->getUpdatedAt()); |
|
| 135 | $this->assertLessThan(3, $this->comment->getUpdatedAt()->diff(new \DateTime())->s); |
|
| 136 | } |
|
| 137 | } |
|
| 138 | ||
| @@ 106-114 (lines=9) @@ | ||
| 103 | $this->assertSame($testName, $this->entity->getName()); |
|
| 104 | } |
|
| 105 | ||
| 106 | public function testPrePersist() |
|
| 107 | { |
|
| 108 | $this->assertNull($this->entity->getCreatedAt()); |
|
| 109 | ||
| 110 | $this->entity->prePersist(); |
|
| 111 | ||
| 112 | $this->assertInstanceOf('DateTime', $this->entity->getCreatedAt()); |
|
| 113 | $this->assertLessThan(3, $this->entity->getCreatedAt()->diff(new \DateTime())->s); |
|
| 114 | } |
|
| 115 | ||
| 116 | public function testPreUpdate() |
|
| 117 | { |
|
| @@ 116-124 (lines=9) @@ | ||
| 113 | $this->assertLessThan(3, $this->entity->getCreatedAt()->diff(new \DateTime())->s); |
|
| 114 | } |
|
| 115 | ||
| 116 | public function testPreUpdate() |
|
| 117 | { |
|
| 118 | $this->assertNull($this->entity->getUpdatedAt()); |
|
| 119 | ||
| 120 | $this->entity->preUpdate(); |
|
| 121 | ||
| 122 | $this->assertInstanceOf('DateTime', $this->entity->getUpdatedAt()); |
|
| 123 | $this->assertLessThan(3, $this->entity->getUpdatedAt()->diff(new \DateTime())->s); |
|
| 124 | } |
|
| 125 | } |
|
| 126 | ||
| @@ 44-52 (lines=9) @@ | ||
| 41 | ]; |
|
| 42 | } |
|
| 43 | ||
| 44 | public function testPrePersist() |
|
| 45 | { |
|
| 46 | $this->assertNull($this->entity->getCreatedAt()); |
|
| 47 | ||
| 48 | $this->entity->prePersist(); |
|
| 49 | ||
| 50 | $this->assertInstanceOf('DateTime', $this->entity->getCreatedAt()); |
|
| 51 | $this->assertLessThan(3, $this->entity->getCreatedAt()->diff(new \DateTime())->s); |
|
| 52 | } |
|
| 53 | ||
| 54 | public function testPreUpdate() |
|
| 55 | { |
|
| @@ 54-62 (lines=9) @@ | ||
| 51 | $this->assertLessThan(3, $this->entity->getCreatedAt()->diff(new \DateTime())->s); |
|
| 52 | } |
|
| 53 | ||
| 54 | public function testPreUpdate() |
|
| 55 | { |
|
| 56 | $this->assertNull($this->entity->getUpdatedAt()); |
|
| 57 | ||
| 58 | $this->entity->preUpdate(); |
|
| 59 | ||
| 60 | $this->assertInstanceOf('DateTime', $this->entity->getUpdatedAt()); |
|
| 61 | $this->assertLessThan(3, $this->entity->getUpdatedAt()->diff(new \DateTime())->s); |
|
| 62 | } |
|
| 63 | } |
|
| 64 | ||
| @@ 72-80 (lines=9) @@ | ||
| 69 | ]; |
|
| 70 | } |
|
| 71 | ||
| 72 | public function testPrePersist() |
|
| 73 | { |
|
| 74 | $this->assertNull($this->entity->getCreatedAt()); |
|
| 75 | ||
| 76 | $this->entity->prePersist(); |
|
| 77 | ||
| 78 | $this->assertInstanceOf('DateTime', $this->entity->getCreatedAt()); |
|
| 79 | $this->assertLessThan(3, $this->entity->getCreatedAt()->diff(new \DateTime())->s); |
|
| 80 | } |
|
| 81 | ||
| 82 | public function testPreUpdate() |
|
| 83 | { |
|
| @@ 82-90 (lines=9) @@ | ||
| 79 | $this->assertLessThan(3, $this->entity->getCreatedAt()->diff(new \DateTime())->s); |
|
| 80 | } |
|
| 81 | ||
| 82 | public function testPreUpdate() |
|
| 83 | { |
|
| 84 | $this->assertNull($this->entity->getUpdatedAt()); |
|
| 85 | ||
| 86 | $this->entity->preUpdate(); |
|
| 87 | ||
| 88 | $this->assertInstanceOf('DateTime', $this->entity->getUpdatedAt()); |
|
| 89 | $this->assertLessThan(3, $this->entity->getUpdatedAt()->diff(new \DateTime())->s); |
|
| 90 | } |
|
| 91 | ||
| 92 | public function testLeadsInteraction() |
|
| 93 | { |
|