Sha256: 7637801643c82328e6d3a25435217a69e3d39c49aae28fb97e8b2294e7719497
Contents?: true
Size: 824 Bytes
Versions: 4
Compression:
Stored size: 824 Bytes
Contents
# encoding: UTF-8 # To make testing/debugging easier, test within this source tree versus an installed gem dir = File.dirname(__FILE__) ROOT_DIR = File.expand_path(File.join(dir, '..')) LIB_DIR = File.expand_path(File.join(ROOT_DIR, 'lib')) $LOAD_PATH << LIB_DIR require 'rubygems' require 'free-image' require 'tempfile' def image_path(image) File.join(ROOT_DIR, 'test', 'images', image) end def image_data(image) path = File.join(ROOT_DIR, 'test', 'images', image) result = nil File.open(path, 'rb') do |file| result = file.read end result end def sample_image path = File.join(ROOT_DIR, 'test', 'images', 'sample.png') FreeImage::Bitmap.open(path) end def lena_image path = File.join(ROOT_DIR, 'test', 'images', 'lena.png') FreeImage::Bitmap.open(path) end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
free-image-0.6.2 | test/test_helper.rb |
free-image-0.6.1 | test/test_helper.rb |
free-image-0.6.0 | test/test_helper.rb |
free-image-0.5.0 | test/test_helper.rb |