Sha256: 396eecebfe4b418536ca8e3752ea5ce16d3e0014c76e5b044c0e514057e59d62

Contents?: true

Size: 293 Bytes

Versions: 5

Compression:

Stored size: 293 Bytes

Contents

module Spec

  class InstanceHelper < ShouldBase
  
    def initialize(target)
      @target = target
    end
    
    def of(expected_class)
      fail_with_message(default_message("should be an instance of", expected_class)) unless @target.instance_of? expected_class
    end
    
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
rspec-0.5.12 lib/spec/api/helper/instance_helper.rb
rspec-0.5.13 lib/spec/api/helper/instance_helper.rb
rspec-0.5.14 lib/spec/api/helper/instance_helper.rb
rspec-0.5.15 lib/spec/api/helper/instance_helper.rb
rspec-0.5.16 lib/spec/api/helper/instance_helper.rb