-<?php namespace Tests\Entity;
+<?php
-use BookStack\Entities\Tools\SearchOptions;
+namespace Tests\Entity;
+
+use BookStack\Search\SearchOptions;
use Tests\TestCase;
class SearchOptionsTest extends TestCase
public function test_to_string_includes_all_items_in_the_correct_format()
{
$expected = 'cat "dog" [tag=good] {is_tree}';
- $options = new SearchOptions;
+ $options = new SearchOptions();
$options->searches = ['cat'];
$options->exacts = ['dog'];
$options->tags = ['tag=good'];
$this->assertEquals([
'is_tree' => '',
- 'name' => 'dan',
- 'cat' => 'happy',
+ 'name' => 'dan',
+ 'cat' => 'happy',
], $opts->filters);
}
}