Skip to content

Commit

Permalink
Add test case to produce a bug about group mention space
Browse files Browse the repository at this point in the history
  • Loading branch information
r7kamura committed Nov 22, 2016
1 parent d83d5ea commit 16204ee
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions spec/qiita/markdown/processor_spec.rb
Expand Up @@ -491,6 +491,22 @@
end
end

context "with group mention following another text" do
let(:context) do
super().merge(group_mention_url_generator: lambda do |group|
"https://#{group[:team_url_name]}.example.com/groups/#{group[:group_url_name]}"
end)
end

let(:markdown) do
"FYI @alice/bob"
end

it "preserves space after preceding text" do
is_expected.to start_with("<p>FYI <a ")
end
end

context "with normal link" do
let(:markdown) do
"[](/example)"
Expand Down

0 comments on commit 16204ee

Please sign in to comment.