diff --git a/plugins/discourse-details/spec/components/pretty_text_spec.rb b/plugins/discourse-details/spec/components/pretty_text_spec.rb new file mode 100644 index 0000000000..b9b91ea771 --- /dev/null +++ b/plugins/discourse-details/spec/components/pretty_text_spec.rb @@ -0,0 +1,12 @@ +require 'rails_helper' +require 'pretty_text' + +describe PrettyText do + + it "supports details tag" do + cooked_html = "
foo\n\n

bar

\n\n

" + expect(PrettyText.cook("
foobar
")).to match_html(cooked_html) + expect(PrettyText.cook("[details=foo]bar[/details]")).to match_html(cooked_html) + end + +end