mirror of
https://github.com/BookStackApp/BookStack.git
synced 2026-01-03 23:42:28 +03:00
Input WYSIWYG: Aligned newline handling with old descriptions
To ensure consistenent behaviour before/after changes. Added tests to cover.
This commit is contained in:
@@ -278,6 +278,17 @@ class BookTest extends TestCase
|
||||
$this->assertEquals($expected, $book->description_html);
|
||||
}
|
||||
|
||||
public function test_show_view_displays_description_if_no_description_html_set()
|
||||
{
|
||||
$book = $this->entities->book();
|
||||
$book->description_html = '';
|
||||
$book->description = "My great\ndescription\n\nwith newlines";
|
||||
$book->save();
|
||||
|
||||
$resp = $this->asEditor()->get($book->getUrl());
|
||||
$resp->assertSee("<p>My great<br>\ndescription<br>\n<br>\nwith newlines</p>", false);
|
||||
}
|
||||
|
||||
public function test_show_view_has_copy_button()
|
||||
{
|
||||
$book = $this->entities->book();
|
||||
|
||||
Reference in New Issue
Block a user