Sha256: 9c310baf2c5c5fef76d5043adccddb88a6ad86c5947bd0ee5e21fe0a4901552d

Contents?: true

Size: 573 Bytes

Versions: 12

Compression:

Stored size: 573 Bytes

Contents

require "spec_helper"

describe Sprite do
  before(:all) do
    MockImage = Struct.new :width, :height, :top, :left
    @sprites = Environment.new(root.join "config.yml").sprites
    image0 = MockImage.new 2, 3
    image1 = MockImage.new 5, 3
    image2 = MockImage.new 6, 2
    image3 = MockImage.new 2, 24
    image4 = MockImage.new 1, 3
    @images = [image0, image1, image2, image3, image4]
  end

  it "should be an empty hash" do
    @sprites.should eql(Hash.new)
  end

  it "should be fit in blocks" do
    sprites = Sprite.new(@images)
    sprites.pack!
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
linner-0.7.3 spec/linner/sprites_spec.rb
linner-0.7.2 spec/linner/sprites_spec.rb
linner-0.7.1 spec/linner/sprites_spec.rb
linner-0.7.0 spec/linner/sprites_spec.rb
linner-0.6.7 spec/linner/sprites_spec.rb
linner-0.6.6 spec/linner/sprites_spec.rb
linner-0.6.5 spec/linner/sprites_spec.rb
linner-0.6.4 spec/linner/sprites_spec.rb
linner-0.6.3 spec/linner/sprites_spec.rb
linner-0.6.2 spec/linner/sprites_spec.rb
linner-0.6.1 spec/linner/sprites_spec.rb
linner-0.6.0 spec/linner/sprites_spec.rb