/**
* @group unit
*/
public function testConstantScoreWithLegacyFilterDeprecated()
{
$this->hideDeprecated();
$existsFilter = new Exists('test');
$this->showDeprecated();
$queryDSL = new DSL\Query();
$errorsCollector = $this->startCollectErrors();
$queryDSL->constant_score($existsFilter);
$this->finishCollectErrors();
$errorsCollector->assertOnlyDeprecatedErrors(array('Deprecated: Elastica\\Query\\ConstantScore passing AbstractFilter is deprecated. Pass AbstractQuery instead.', 'Deprecated: Elastica\\Query\\ConstantScore::setFilter passing AbstractFilter is deprecated. Pass AbstractQuery instead.'));
}