paperclip 2.7.1 → 2.7.2

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of paperclip might be problematic. Click here for more details.

@@ -1,3 +1,3 @@
1
1
  module Paperclip
2
- VERSION = "2.7.1" unless defined? Paperclip::VERSION
2
+ VERSION = "2.7.2" unless defined? Paperclip::VERSION
3
3
  end
@@ -34,7 +34,7 @@ Gem::Specification.new do |s|
34
34
  s.add_development_dependency('aruba')
35
35
  s.add_development_dependency('capybara')
36
36
  s.add_development_dependency('bundler')
37
- s.add_development_dependency('cocaine', '~> 0.2')
37
+ s.add_development_dependency('cocaine', '~> 0.3.0')
38
38
  s.add_development_dependency('fog')
39
39
  s.add_development_dependency('rake')
40
40
  s.add_development_dependency('fakeweb')
@@ -96,40 +96,46 @@ class StyleTest < Test::Unit::TestCase
96
96
  end
97
97
 
98
98
  context "An attachment with :convert_options" do
99
- setup do
99
+ should "not have called extra_options_for(:thumb/:large) on initialization" do
100
100
  @attachment = attachment :path => ":basename.:extension",
101
101
  :styles => {:thumb => "100x100", :large => "400x400"},
102
102
  :convert_options => {:all => "-do_stuff", :thumb => "-thumbnailize"}
103
+ @attachment.expects(:extra_options_for).never
103
104
  @style = @attachment.styles[:thumb]
104
105
  @file = StringIO.new("...")
105
106
  @file.stubs(:original_filename).returns("file.jpg")
106
107
  end
107
108
 
108
- before_should "not have called extra_options_for(:thumb/:large) on initialization" do
109
- @attachment.expects(:extra_options_for).never
110
- end
111
-
112
109
  should "call extra_options_for(:thumb/:large) when convert options are requested" do
110
+ @attachment = attachment :path => ":basename.:extension",
111
+ :styles => {:thumb => "100x100", :large => "400x400"},
112
+ :convert_options => {:all => "-do_stuff", :thumb => "-thumbnailize"}
113
+ @style = @attachment.styles[:thumb]
114
+ @file = StringIO.new("...")
115
+ @file.stubs(:original_filename).returns("file.jpg")
113
116
  @attachment.expects(:extra_options_for).with(:thumb)
114
117
  @attachment.styles[:thumb].convert_options
115
118
  end
116
119
  end
117
120
 
118
121
  context "An attachment with :source_file_options" do
119
- setup do
122
+ should "not have called extra_source_file_options_for(:thumb/:large) on initialization" do
120
123
  @attachment = attachment :path => ":basename.:extension",
121
124
  :styles => {:thumb => "100x100", :large => "400x400"},
122
125
  :source_file_options => {:all => "-density 400", :thumb => "-depth 8"}
126
+ @attachment.expects(:extra_source_file_options_for).never
123
127
  @style = @attachment.styles[:thumb]
124
128
  @file = StringIO.new("...")
125
129
  @file.stubs(:original_filename).returns("file.jpg")
126
130
  end
127
131
 
128
- before_should "not have called extra_source_file_options_for(:thumb/:large) on initialization" do
129
- @attachment.expects(:extra_source_file_options_for).never
130
- end
131
-
132
132
  should "call extra_options_for(:thumb/:large) when convert options are requested" do
133
+ @attachment = attachment :path => ":basename.:extension",
134
+ :styles => {:thumb => "100x100", :large => "400x400"},
135
+ :source_file_options => {:all => "-density 400", :thumb => "-depth 8"}
136
+ @style = @attachment.styles[:thumb]
137
+ @file = StringIO.new("...")
138
+ @file.stubs(:original_filename).returns("file.jpg")
133
139
  @attachment.expects(:extra_source_file_options_for).with(:thumb)
134
140
  @attachment.styles[:thumb].source_file_options
135
141
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: paperclip
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.7.1
4
+ version: 2.7.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-09-28 00:00:00.000000000 Z
12
+ date: 2012-10-19 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activerecord
@@ -226,7 +226,7 @@ dependencies:
226
226
  requirements:
227
227
  - - ~>
228
228
  - !ruby/object:Gem::Version
229
- version: '0.2'
229
+ version: 0.3.0
230
230
  type: :development
231
231
  prerelease: false
232
232
  version_requirements: !ruby/object:Gem::Requirement
@@ -234,7 +234,7 @@ dependencies:
234
234
  requirements:
235
235
  - - ~>
236
236
  - !ruby/object:Gem::Version
237
- version: '0.2'
237
+ version: 0.3.0
238
238
  - !ruby/object:Gem::Dependency
239
239
  name: fog
240
240
  requirement: !ruby/object:Gem::Requirement