|
@@ 143-151 (lines=9) @@
|
| 140 |
|
/** |
| 141 |
|
* @covers \eZ\Publish\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase::untrashLocation |
| 142 |
|
*/ |
| 143 |
|
public function testUntrashInvalidLocation() |
| 144 |
|
{ |
| 145 |
|
$this->expectException(\eZ\Publish\API\Repository\Exceptions\NotFoundException::class); |
| 146 |
|
|
| 147 |
|
$this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); |
| 148 |
|
$handler = $this->getLocationGateway(); |
| 149 |
|
|
| 150 |
|
$handler->untrashLocation(23); |
| 151 |
|
} |
| 152 |
|
|
| 153 |
|
/** |
| 154 |
|
* @covers \eZ\Publish\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase::untrashLocation |
|
@@ 156-165 (lines=10) @@
|
| 153 |
|
/** |
| 154 |
|
* @covers \eZ\Publish\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase::untrashLocation |
| 155 |
|
*/ |
| 156 |
|
public function testUntrashLocationInvalidParent() |
| 157 |
|
{ |
| 158 |
|
$this->expectException(\eZ\Publish\API\Repository\Exceptions\NotFoundException::class); |
| 159 |
|
|
| 160 |
|
$this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); |
| 161 |
|
$handler = $this->getLocationGateway(); |
| 162 |
|
$handler->trashLocation(71); |
| 163 |
|
|
| 164 |
|
$handler->untrashLocation(71, 1337); |
| 165 |
|
} |
| 166 |
|
|
| 167 |
|
/** |
| 168 |
|
* @covers \eZ\Publish\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase::untrashLocation |
|
@@ 170-181 (lines=12) @@
|
| 167 |
|
/** |
| 168 |
|
* @covers \eZ\Publish\Core\Persistence\Legacy\Content\Location\Gateway\DoctrineDatabase::untrashLocation |
| 169 |
|
*/ |
| 170 |
|
public function testUntrashLocationInvalidOldParent() |
| 171 |
|
{ |
| 172 |
|
$this->expectException(\eZ\Publish\API\Repository\Exceptions\NotFoundException::class); |
| 173 |
|
|
| 174 |
|
$this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); |
| 175 |
|
$handler = $this->getLocationGateway(); |
| 176 |
|
$handler->trashLocation(71); |
| 177 |
|
$handler->trashLocation(70); |
| 178 |
|
|
| 179 |
|
$handler->untrashLocation(70); |
| 180 |
|
$handler->untrashLocation(71); |
| 181 |
|
} |
| 182 |
|
|
| 183 |
|
public static function getLoadTrashValues() |
| 184 |
|
{ |