mirror of
https://github.com/openSUSE/osem.git
synced 2026-08-13 11:44:02 +00:00
Add test of markdown link protocol sanitization
This commit is contained in:
parent
e486ce55d7
commit
a281110b29
1 changed files with 4 additions and 0 deletions
|
|
@ -9,6 +9,10 @@ describe FormatHelper, type: :helper do
|
|||
expect(markdown(nil)).to eq ''
|
||||
end
|
||||
|
||||
it "doesn't render unsafe URI schemes" do
|
||||
expect(markdown('[a](javascript:b)')).to eq "<p><a>a</a></p>\n"
|
||||
end
|
||||
|
||||
it 'should return HTML for header markdown' do
|
||||
expect(markdown('# this is my header')).to eq "<h1>this is my header</h1>\n"
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue