diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-04-01 00:08:16 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-04-01 00:08:16 +0300 |
commit | 32bbedbc214c30979168c8005c83259feb468540 (patch) | |
tree | 4fdc4817df2ce77440cd4894759100bbb22df806 /spec/initializers/rdoc_segfault_patch_spec.rb | |
parent | e7fb61499317b3c044845817b991e13aea276955 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/initializers/rdoc_segfault_patch_spec.rb')
-rw-r--r-- | spec/initializers/rdoc_segfault_patch_spec.rb | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/spec/initializers/rdoc_segfault_patch_spec.rb b/spec/initializers/rdoc_segfault_patch_spec.rb new file mode 100644 index 00000000000..f9630295052 --- /dev/null +++ b/spec/initializers/rdoc_segfault_patch_spec.rb @@ -0,0 +1,24 @@ +# frozen_string_literal: true + +RSpec.describe 'RDoc segfault patch fix' do + describe 'RDoc::Markup::ToHtml' do + describe '#parseable?' do + it 'returns false' do + to_html = RDoc::Markup::ToHtml.new( nil) + + expect(to_html.parseable?('"def foo; end"')).to eq(false) + end + end + end + + describe 'RDoc::Markup::Verbatim' do + describe 'ruby?' do + it 'returns false' do + verbatim = RDoc::Markup::Verbatim.new('def foo; end') + verbatim.format = :ruby + + expect(verbatim.ruby?).to eq(false) + end + end + end +end |