Sha256: a2e20ebff517501436adc0923b8a84ca2fe01300c9770f0a95e5111377889a48

Contents?: true

Size: 576 Bytes

Versions: 95

Compression:

Stored size: 576 Bytes

Contents

require File.dirname(__FILE__) + '/../spec_helper'

describe "Kernel extensions" do
  before(:each) do
    @obj = Object.new
  end
  it "should eval the string into time" do
    @obj.should_receive(:sleep).once.with(10.seconds).and_return true
    @obj.wait "10.seconds"
  end
end
describe "Object extensions" do
  before(:each) do
    @klass = Object.new
    @klass.instance_eval <<-EOE
      def hello
        puts "hello"
      end
    EOE
  end
  it "should be able to get a list of the defined methods on the object" do
    @klass.my_methods.should == ["hello"]
  end
end

Version data entries

95 entries across 95 versions & 3 rubygems

Version Path
auser-poolparty-0.2.88 spec/poolparty/core/kernel_spec.rb
auser-poolparty-0.2.89 spec/poolparty/core/kernel_spec.rb
auser-poolparty-0.2.9 spec/poolparty/core/kernel_spec.rb
auser-poolparty-0.2.90 spec/poolparty/core/kernel_spec.rb
auser-poolparty-0.2.91 spec/poolparty/core/kernel_spec.rb
auser-poolparty-0.2.92 spec/poolparty/core/kernel_spec.rb
auser-poolparty-0.2.93 spec/poolparty/core/kernel_spec.rb
auser-poolparty-0.2.94 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.0.0 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.1.1 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.1.3 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.1.4 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.1.5 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.1.6 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.1.7 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.2.0 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.2.1 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.2.10 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.2.11 spec/poolparty/core/kernel_spec.rb
auser-poolparty-1.2.12 spec/poolparty/core/kernel_spec.rb