11 lines
304 B
Ruby
11 lines
304 B
Ruby
|
describe Gitlab::Diff::Line do
|
||
|
context "when setting rich text" do
|
||
|
it 'escapes any HTML special characters in the diff chunk header' do
|
||
|
subject = described_class.new("<input>", "", 0, 0, 0)
|
||
|
line = subject.as_json
|
||
|
|
||
|
expect(line[:rich_text]).to eq("<input>")
|
||
|
end
|
||
|
end
|
||
|
end
|