Sha256: bf0683b640ced42aac7239e830b1d0c49f6b2c39be62d8c89974650571e3ccf3
Contents?: true
Size: 652 Bytes
Versions: 2
Compression:
Stored size: 652 Bytes
Contents
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib')) require 'rubygems' require 'bundler' Bundler.setup require 'spec' require 'chunky_png' module ResourceFileHelper def resource_file(name) File.expand_path("./resources/#{name}", File.dirname(__FILE__)) end end module MatrixSpecHelper def display(canvas) filename = resource_file('_tmp.png') canvas.to_datastream.save(filename) `open #{filename}` end def reference_canvas(name) ChunkyPNG::Canvas.from_file(resource_file("#{name}.png")) end end Spec::Runner.configure do |config| config.include ResourceFileHelper config.include MatrixSpecHelper end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
chunky_png-0.9.1 | spec/spec_helper.rb |
chunky_png-0.9.0 | spec/spec_helper.rb |