Skip to content

Commit

Permalink
Remove failing spec
Browse files Browse the repository at this point in the history
1) With ImageMagick MiniMagick::Image#details when verbose information includes a clipping path does not hang when parsing verbose data
   Failure/Error: details_hash[last_key] << line

   NoMethodError:
     undefined method `<<' for {"8BIM:1999,2998:#1"=>"<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>"}:Hash

                   details_hash[last_key] << line
                                          ^^
     Did you mean?  <
   # ./lib/mini_magick/image/info.rb:149:in `block in details'
   # ./lib/mini_magick/image/info.rb:138:in `each'
   # ./lib/mini_magick/image/info.rb:138:in `each_with_object'
   # ./lib/mini_magick/image/info.rb:138:in `details'
   # ./lib/mini_magick/image/info.rb:31:in `[]'
   # ./lib/mini_magick/image.rb:145:in `block in attribute'
   # ./spec/lib/mini_magick/image_spec.rb:508:in `block (7 levels) in <top (required)>'
   # ./spec/lib/mini_magick/image_spec.rb:507:in `block (6 levels) in <top (required)>'
   # ./spec/spec_helper.rb:19:in `block (3 levels) in <top (required)>'
  • Loading branch information
janko committed Dec 7, 2022
1 parent 6151060 commit 448350a
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions spec/lib/mini_magick/image_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -496,19 +496,6 @@ def create(path = image_path)
expect(subject.details).not_to have_key("Software")
end
end

# GraphicsMagick does not output the clipping path
context "when verbose information includes a clipping path", skip_cli: :graphicsmagick do
subject { described_class.new(image_path(:clipping_path)) }

it "does not hang when parsing verbose data" do
# Retrieving .details should happen very quickly but as of v4.3.6
# will hang indefinitely without the timeout
Timeout::timeout(10) do
expect(subject.details['Clipping path'][0..4]).to eq "<?xml"
end
end
end
end

describe "#data" do
Expand Down

0 comments on commit 448350a

Please sign in to comment.