summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorSean McGivern <sean@mcgivern.me.uk>2016-10-19 13:56:08 +0000
committerSean McGivern <sean@mcgivern.me.uk>2016-10-19 13:56:08 +0000
commitcc46a0d47c5660583455c203a93f3333af42f4a8 (patch)
treedeef0c7ac7a1bd2468a576556c7971a8abc3e7d4 /spec
parent12f649fe2a83dd637aeb700fc98cdcfcd9ac2100 (diff)
parent9c8c5e9dc050f32cec05f6903105ff34d726979b (diff)
downloadgitlab-ce-cc46a0d47c5660583455c203a93f3333af42f4a8.tar.gz
Merge branch 'fix-escaping' into 'master'
fix: commit messages being double-escaped in activities tab See merge request !6937
Diffstat (limited to 'spec')
-rw-r--r--spec/lib/banzai/filter/html_entity_filter_spec.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/spec/lib/banzai/filter/html_entity_filter_spec.rb b/spec/lib/banzai/filter/html_entity_filter_spec.rb
index 4c68ce6d6e4..f9e6bd609f0 100644
--- a/spec/lib/banzai/filter/html_entity_filter_spec.rb
+++ b/spec/lib/banzai/filter/html_entity_filter_spec.rb
@@ -11,4 +11,9 @@ describe Banzai::Filter::HtmlEntityFilter, lib: true do
expect(output).to eq(escaped)
end
+
+ it 'does not double-escape' do
+ escaped = ERB::Util.html_escape("Merge branch 'blabla' into 'master'")
+ expect(filter(escaped)).to eq(escaped)
+ end
end