/**
* Scroll must not overwrite options.
*
* @group functional
*/
public function testSearchRevert()
{
$search = $this->_prepareSearch();
$search->setOption(Search::OPTION_SCROLL, 'must');
$search->setOption(Search::OPTION_SCROLL_ID, 'not');
$search->setOption(Search::OPTION_SEARCH_TYPE, 'change');
$old = $search->getOptions();
$scroll = new Scroll($search);
$scroll->rewind();
$this->assertEquals($old, $search->getOptions());
$scroll->next();
$this->assertEquals($old, $search->getOptions());
}