Verified Commit bdd98ee7 authored by Haelwenn's avatar Haelwenn

AutoLinker.BuilderTest: Do not pass overridden href to create_link/2

parent 204ad610
Pipeline #8272 passed with stages
in 58 seconds
......@@ -8,15 +8,15 @@ defmodule AutoLinker.BuilderTest do
expected =
"<a href=\"http://text\" class=\"auto-linker\" target=\"_blank\" rel=\"noopener noreferrer\">text</a>"
assert create_link("text", %{href: "url"}) == expected
assert create_link("text", %{}) == expected
expected = "<a href=\"http://text\" class=\"auto-linker\" target=\"_blank\">text</a>"
assert create_link("text", %{href: "url", rel: nil}) == expected
assert create_link("text", %{rel: nil}) == expected
expected =
"<a href=\"http://text\" class=\"auto-linker\" target=\"_blank\" rel=\"me\">text</a>"
assert create_link("text", %{href: "url", rel: "me"}) == expected
assert create_link("text", %{rel: "me"}) == expected
end
test "create_markdown_links/2" do
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment