|
@@ 106-119 (lines=14) @@
|
| 103 |
|
/** |
| 104 |
|
* @dataProvider getLoadLocationValues |
| 105 |
|
*/ |
| 106 |
|
public function testLoadLocationDataByContent($field, $value) |
| 107 |
|
{ |
| 108 |
|
$this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); |
| 109 |
|
|
| 110 |
|
$gateway = $this->getLocationGateway(); |
| 111 |
|
|
| 112 |
|
$locationsData = $gateway->loadLocationDataByContent(75); |
| 113 |
|
|
| 114 |
|
$this->assertCount(1, $locationsData); |
| 115 |
|
|
| 116 |
|
$locationRow = reset($locationsData); |
| 117 |
|
|
| 118 |
|
$this->assertEquals($value, $locationRow[$field]); |
| 119 |
|
} |
| 120 |
|
|
| 121 |
|
/** |
| 122 |
|
* @dataProvider getLoadLocationValues |
|
@@ 124-137 (lines=14) @@
|
| 121 |
|
/** |
| 122 |
|
* @dataProvider getLoadLocationValues |
| 123 |
|
*/ |
| 124 |
|
public function testLoadParentLocationDataForDraftContentAll($field, $value) |
| 125 |
|
{ |
| 126 |
|
$this->insertDatabaseFixture(__DIR__ . '/_fixtures/full_example_tree.php'); |
| 127 |
|
|
| 128 |
|
$gateway = $this->getLocationGateway(); |
| 129 |
|
|
| 130 |
|
$locationsData = $gateway->loadParentLocationsDataForDraftContent(226); |
| 131 |
|
|
| 132 |
|
$this->assertCount(1, $locationsData); |
| 133 |
|
|
| 134 |
|
$locationRow = reset($locationsData); |
| 135 |
|
|
| 136 |
|
$this->assertEquals($value, $locationRow[$field]); |
| 137 |
|
} |
| 138 |
|
|
| 139 |
|
public function testLoadLocationDataByContentLimitSubtree() |
| 140 |
|
{ |