Skip to content

Commit

Permalink
ruflin#1184 Remove Filtered query:
Browse files Browse the repository at this point in the history
- Remove Elastica/Query/Filtered.php
- Remove test/Elastica/Query/FilteredTest.php
- Remove all references for filtered query from code
- Changelog update
  • Loading branch information
bopop committed Oct 24, 2016
1 parent 11af175 commit dcaa8ce
Show file tree
Hide file tree
Showing 6 changed files with 2 additions and 255 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ All notable changes to this project will be documented in this file based on the
- Removing all deprecated filters including tests. Use queries instead.
- Remove deprecated Elastica\Script*.php classes. Use Elastica\Script\* instead.
- Remove Elastica/Query/Image.php and test/Elastica/Query/ImageTest.php, no more support for image-plugin.
- Remove Elastica/Query/Filtered.php and test/Elastica/Query/FilteredTest.php and all uses from code.

### Bugfixes

Expand Down
22 changes: 0 additions & 22 deletions lib/Elastica/Query/Builder.php
Original file line number Diff line number Diff line change
Expand Up @@ -384,28 +384,6 @@ public function filterClose()
return $this->close();
}

/**
* Query.
*
* @return $this
*/
public function filteredQuery()
{
return $this->fieldOpen('filtered');
}

/**
* Close a 'filtered_query' block.
*
* Alias of close() for ease of reading in source.
*
* @return $this
*/
public function filteredQueryClose()
{
return $this->fieldClose();
}

/**
* Set the from parameter (offset).
*
Expand Down
100 changes: 0 additions & 100 deletions lib/Elastica/Query/Filtered.php

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public function testPartialFailure()

$query = Query::create([
'query' => [
'filtered' => [
'bool' => [
'filter' => [
'script' => [
'script' => 'doc["undefined"] > 8', // compiles, but doesn't work
Expand Down
3 changes: 0 additions & 3 deletions test/lib/Elastica/Test/Query/BuilderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ public function getQueryTypes()
['constantScore', 'constant_score'],
['disMax', 'dis_max'],
['filter', 'filter'],
['filteredQuery', 'filtered'],
['must', 'must'],
['mustNot', 'must_not'],
['prefix', 'prefix'],
Expand Down Expand Up @@ -137,8 +136,6 @@ public function getQueryTypes()
* @covers \Elastica\Query\Builder::disMaxClose
* @covers \Elastica\Query\Builder::filter
* @covers \Elastica\Query\Builder::filterClose
* @covers \Elastica\Query\Builder::filteredQuery
* @covers \Elastica\Query\Builder::filteredQueryClose
* @covers \Elastica\Query\Builder::must
* @covers \Elastica\Query\Builder::mustClose
* @covers \Elastica\Query\Builder::mustNot
Expand Down
129 changes: 0 additions & 129 deletions test/lib/Elastica/Test/Query/FilteredTest.php

This file was deleted.

0 comments on commit dcaa8ce

Please sign in to comment.