Sha256: 1c7ab5e83a4dacb8c70eb9321f948c9c4978bb964487446e8e911c3bffd0f7f2
Contents?: true
Size: 765 Bytes
Versions: 13
Compression:
Stored size: 765 Bytes
Contents
require File.expand_path('../test_helper', __FILE__) class ImgTest < UnitTest Image = Sinatra::AssetPack::Image test "get img" do get '/images/email.png' assert_equal last_response.headers['Content-Length'], File.size(r("/app/images/email.png")).to_s end test "get img with cache buster" do get '/images/email.893748.png' assert_equal last_response.headers['Content-Length'], File.size(r("/app/images/email.png")).to_s end test "Image[]" do i = Image['/app/images/email.png'] j = Image['/app/images/email.png'] assert j === i end test "Image[]" do i = Image['/app/images/email.png'] j = Image['/app/images/email.png'] Image.any_instance.expects(:`).times(1) j.dimensions i.dimensions end end
Version data entries
13 entries across 13 versions & 3 rubygems