Sha256: b8651ded14ddd092458ab2e39d3fbf50156f65c148359ef1eea653cb85365b29

Contents?: true

Size: 630 Bytes

Versions: 6

Compression:

Stored size: 630 Bytes

Contents

require File.join(File.dirname(__FILE__),'helper')
require 'physical'
require 'actor'

class CircleActor < Actor
  has_behaviors :physical => {:shape => :circle, 
    :mass => 500,
    :radius => 10}
end

describe 'A new physical behavior' do
  before do
    @stage = stub(:load_animation_set => ['1.png_img_obj','2.png_img_obj'],:register_physical_object => true)

    opts = {:stage=>@stage, :input=>"input", :resources=>"rm"}
    @actor = CircleActor.new opts
    @physical = @actor.physical
  end

  it 'should add methods to its actor' do
    @actor.should.respond_to? :x
    pending 'testing this feels dirty...'
  end

end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
gamebox-0.2.1 spec/physical_spec.rb
gamebox-0.1.1 spec/physical_spec.rb
gamebox-0.1.0 spec/physical_spec.rb
gamebox-0.0.9 spec/physical_spec.rb
gamebox-0.0.8 spec/physical_spec.rb
gamebox-0.0.7 spec/physical_spec.rb