| @@ 371-384 (lines=14) @@ | ||
| 368 | ); |
|
| 369 | } |
|
| 370 | ||
| 371 | public function testContentDepthFilterIn() |
|
| 372 | { |
|
| 373 | $this->assertSearchResults( |
|
| 374 | array(2, 5, 12, 13, 14, 43, 44, 48, 51, 52, 53, 54, 56, 58, 59, 69, 77, 86, 96, 107, 153, 156, 167, 190, 227), |
|
| 375 | $this->getContentSearchHandler()->findLocations( |
|
| 376 | new LocationQuery( |
|
| 377 | array( |
|
| 378 | 'filter' => new Criterion\Location\Depth(Criterion\Operator::IN, array(1, 2)), |
|
| 379 | 'limit' => 50, |
|
| 380 | ) |
|
| 381 | ) |
|
| 382 | ) |
|
| 383 | ); |
|
| 384 | } |
|
| 385 | ||
| 386 | public function testContentDepthFilterBetween() |
|
| 387 | { |
|
| @@ 445-458 (lines=14) @@ | ||
| 442 | ); |
|
| 443 | } |
|
| 444 | ||
| 445 | public function testContentDepthFilterLessThanOrEqual() |
|
| 446 | { |
|
| 447 | $this->assertSearchResults( |
|
| 448 | array(2, 5, 12, 13, 14, 43, 44, 48, 51, 52, 53, 54, 56, 58, 59, 69, 77, 86, 96, 107, 153, 156, 167, 190, 227), |
|
| 449 | $this->getContentSearchHandler()->findLocations( |
|
| 450 | new LocationQuery( |
|
| 451 | array( |
|
| 452 | 'filter' => new Criterion\Location\Depth(Criterion\Operator::LTE, 2), |
|
| 453 | 'limit' => 50, |
|
| 454 | ) |
|
| 455 | ) |
|
| 456 | ) |
|
| 457 | ); |
|
| 458 | } |
|
| 459 | ||
| 460 | public function testLocationPriorityFilter() |
|
| 461 | { |
|