Sha256: 3f385380d5066c45ec84548adc7dea8fd70e8f436796d35603f1d512f3f9255e
Contents?: true
Size: 1.25 KB
Versions: 16
Compression:
Stored size: 1.25 KB
Contents
require 'spec_helper' describe 'method matcher' do context "content without method" do no_method = %q{ class X hello end} it "should not have method hello" do no_method.should_not have_method :hello do |content| content.should_not be_empty end end end context "content with method hello" do with_method = %q{ def hello blip end} it "should have method hello" do with_method.should have_method :hello do |content| content.should_not be_empty end end end context "content: method hello with args (x, y)" do with_method = %q{ def hello(x, y) blip end} it "should have method hello" do with_method.should have_method :hello, :args => 'x, y' do |content| content.should_not be_empty end end end context "content: method hello with args x, y" do with_method = %q{ def hello x, y blip end} it "should have method hello with args x, y" do with_method.should have_method :hello, :args => 'x, y' do |content| content.should_not be_empty end end end end
Version data entries
16 entries across 16 versions & 1 rubygems