Sha256: 15072f596abc1255d2f407676303d1f681852ef60baa81f38c976ab720ac967b
Contents?: true
Size: 857 Bytes
Versions: 1
Compression:
Stored size: 857 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') describe 'method call matcher' do context "content without method call" do not_call = %q{ def hello end} it "should not have call hello" do not_call.should_not have_call :hello do |content| puts content end end end context "content with call hello" do call = 'hello' it "should have call to hello" do call.should have_call :hello do |content| puts "content: #{content}" end end end context "content with call hello" do call = %q{ def hello x.hello end} it "should have call to hello" do call.should have_dot_call :hello do |content| puts "content: #{content}" end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
generator-spec-0.4.7 | spec/generator_spec/matchers/content/have_call_spec.rb |