]> BookStack Code Mirror - bookstack/blobdiff - tests/Entity/BookTest.php
Updated nav tests to look for shortened item names
[bookstack] / tests / Entity / BookTest.php
index 74b0b0e0b4060f0b26ca808c88b60864cf2088cf..e1b06431b43a2edda49d828ede935fd9392da66f 100644 (file)
@@ -39,11 +39,11 @@ class BookTest extends TestCase
 
         $resp = $this->asEditor()->get($chapter->getUrl());
         $resp->assertElementContains('#sibling-navigation', 'Next');
-        $resp->assertElementContains('#sibling-navigation', $chapter->pages[0]->name);
+        $resp->assertElementContains('#sibling-navigation', substr($chapter->pages[0]->name, 0, 20));
 
         $resp = $this->get($chapter->pages[0]->getUrl());
-        $resp->assertElementContains('#sibling-navigation', $chapter->pages[1]->name);
+        $resp->assertElementContains('#sibling-navigation', substr($chapter->pages[1]->name, 0, 20));
         $resp->assertElementContains('#sibling-navigation', 'Previous');
-        $resp->assertElementContains('#sibling-navigation', $chapter->name);
+        $resp->assertElementContains('#sibling-navigation', substr($chapter->name, 0, 20));
     }
 }
\ No newline at end of file