refactored resizer to use imagemagick, fixed some tests

This commit is contained in:
albert
2011-09-16 12:38:56 -04:00
parent fbc1fb1f51
commit a717134163
31 changed files with 69 additions and 1648 deletions

View File

@@ -38,4 +38,17 @@ class DownloadTest < ActiveSupport::TestCase
assert_match(/image\/gif/, @download.content_type)
end
end
context "a post download for a pixiv manga page" do
setup do
@source = "http://img65.pixiv.net/img/kiyoringo/21755794_p2.png"
@tempfile = Tempfile.new("danbooru-test")
@download = Download.new(@source, @tempfile.path)
end
should "download the big version" do
@download.download!
assert_equal("http://img65.pixiv.net/img/kiyoringo/21755794_big_p2.png", @download.source)
end
end
end