correct specs
This commit is contained in:
parent
c64aabc964
commit
2c6284ece3
|
@ -414,12 +414,14 @@ describe Post do
|
|||
end
|
||||
|
||||
it "ignores pre" do
|
||||
post = Fabricate.build(:post, post_args.merge(raw: "<pre>@Jake</pre> @Finn"))
|
||||
# we need to force an inline
|
||||
post = Fabricate.build(:post, post_args.merge(raw: "p <pre>@Jake</pre> @Finn"))
|
||||
expect(post.raw_mentions).to eq(['finn'])
|
||||
end
|
||||
|
||||
it "catches content between pre tags" do
|
||||
post = Fabricate.build(:post, post_args.merge(raw: "<pre>hello</pre> @Finn <pre></pre>"))
|
||||
# per common mark we need to force an inline
|
||||
post = Fabricate.build(:post, post_args.merge(raw: "a <pre>hello</pre> @Finn <pre></pre>"))
|
||||
expect(post.raw_mentions).to eq(['finn'])
|
||||
end
|
||||
|
||||
|
@ -429,7 +431,7 @@ describe Post do
|
|||
end
|
||||
|
||||
it "ignores quotes" do
|
||||
post = Fabricate.build(:post, post_args.merge(raw: "[quote=\"Evil Trout\"]@Jake[/quote] @Finn"))
|
||||
post = Fabricate.build(:post, post_args.merge(raw: "[quote=\"Evil Trout\"]\n@Jake\n[/quote]\n@Finn"))
|
||||
expect(post.raw_mentions).to eq(['finn'])
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue