forked from AkkomaGang/akkoma
Added a test (written by @andrewzah) for the MR
This commit is contained in:
parent
634c0c52a1
commit
6908f29e0a
1 changed files with 16 additions and 0 deletions
|
@ -784,4 +784,20 @@ test "it returns the tags timeline", %{conn: conn} do
|
|||
assert status["id"] == activity.id
|
||||
end
|
||||
end
|
||||
|
||||
test "Convert newlines to <br> in bio", %{conn: conn} do
|
||||
user = insert(:user)
|
||||
|
||||
conn =
|
||||
conn
|
||||
|> assign(:user, user)
|
||||
|> post("/api/account/update_profile.json", %{
|
||||
"description" => "Hello,\r\nWorld! I\n am a test."
|
||||
})
|
||||
|
||||
user = Repo.get!(User, user.id)
|
||||
assert user.bio == "Hello,<br>World! I<br> am a test."
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue