X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/213a86e3c0ffa36d4aed030eb72d5d65204d02ff..refs/pull/5721/head:/tests/Search/SearchIndexingTest.php diff --git a/tests/Search/SearchIndexingTest.php b/tests/Search/SearchIndexingTest.php index 57cf412e1..d2bbb2905 100644 --- a/tests/Search/SearchIndexingTest.php +++ b/tests/Search/SearchIndexingTest.php @@ -1,6 +1,6 @@ assertNull($scoreByTerm->get($term), "Failed asserting that \"$term\" is not indexed"); } } + + public function test_non_breaking_spaces_handled_as_spaces() + { + $page = $this->entities->newPage(['html' => '
a tigerbadger is a dangerous animal
']); + + $scoreByTerm = $page->searchTerms()->pluck('score', 'term'); + $this->assertNotNull($scoreByTerm->get('tigerbadger')); + $this->assertNotNull($scoreByTerm->get('dangerous')); + $this->assertNotNull($scoreByTerm->get('animal')); + } }