mirror of
https://github.com/discourse/discourse.git
synced 2025-05-30 15:28:37 +08:00
FIX: pinned topic excerpt is not properly truncated
This commit is contained in:
@ -131,6 +131,7 @@ test
|
||||
|
||||
it "should truncate stuff properly" do
|
||||
PrettyText.excerpt("hello world",5).should == "hello…"
|
||||
PrettyText.excerpt("<p>hello</p><p>world</p>",6).should == "hello w…"
|
||||
end
|
||||
|
||||
it "should insert a space between to Ps" do
|
||||
@ -168,6 +169,7 @@ test
|
||||
it "should handle nil" do
|
||||
PrettyText.excerpt(nil,100).should == ''
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user