Created
January 9, 2012 17:45
-
-
Save jimryan/1584077 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
should "process :original style first" do | |
file = File.new(File.join(File.dirname(__FILE__), "fixtures", "50x50.png"), 'rb') | |
rebuild_class :styles => { :small => '100x>', :original => '42x42#' } | |
dummy = Dummy.new | |
dummy.avatar = file | |
dummy.save | |
# :small avatar should be 42px wide (processed original), not 50px (preprocessed original) | |
assert_equal "42", `identify -format "%w" "#{dummy.avatar.path(:small)}"`.strip | |
file.close | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment