Sha256: 47deae1faa220271521c61fada940a38e9aaf22a80b04439b71edf0ceb599d92

Contents?: true

Size: 576 Bytes

Versions: 20

Compression:

Stored size: 576 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
    expect(@sprites).to eq(Hash.new)
  end

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

Version data entries

20 entries across 20 versions & 2 rubygems

Version Path
linner-hc-1.0.0 spec/linner/sprites_spec.rb
linner-0.12.0 spec/linner/sprites_spec.rb
linner-0.11.6 spec/linner/sprites_spec.rb
linner-0.11.5 spec/linner/sprites_spec.rb
linner-0.11.4 spec/linner/sprites_spec.rb
linner-0.11.3 spec/linner/sprites_spec.rb
linner-0.11.2 spec/linner/sprites_spec.rb
linner-0.11.1 spec/linner/sprites_spec.rb
linner-0.11.0 spec/linner/sprites_spec.rb
linner-0.10.0 spec/linner/sprites_spec.rb
linner-0.9.1 spec/linner/sprites_spec.rb
linner-0.9.0 spec/linner/sprites_spec.rb
linner-0.8.7 spec/linner/sprites_spec.rb
linner-0.8.6 spec/linner/sprites_spec.rb
linner-0.8.5 spec/linner/sprites_spec.rb
linner-0.8.4 spec/linner/sprites_spec.rb
linner-0.8.3 spec/linner/sprites_spec.rb
linner-0.8.2 spec/linner/sprites_spec.rb
linner-0.8.1 spec/linner/sprites_spec.rb
linner-0.8.0 spec/linner/sprites_spec.rb