Sha256: 4378fa78d7404b3a30c2b223b2a81c6d6a85306a4e0c8d8a76809cab4e44987b
Contents?: true
Size: 846 Bytes
Versions: 16
Compression:
Stored size: 846 Bytes
Contents
require 'spec_helper' describe Object do before(:each) do @object = Object.new end describe "exclaim" do it "delegates to puts" do @object.should_receive(:puts).once.with :bla @object.exclaim :bla end end describe "timed_exclaim" do it "should exclaim right" do Time.stub! :now => Time.parse('07-03-1977 12:34:56') @object.should_receive(:exclaim).once.with "12:34:56: bla" @object.timed_exclaim 'bla' end end describe 'puts_gem_missing' do it 'should puts right' do @object.should_receive(:puts).once.with "gnorf gem missing!\nTo use gnarble gnarf, you need to:\n 1. Add the following line to Gemfile:\n gem 'gnorf'\n 2. Then, run:\n bundle update\n" @object.puts_gem_missing 'gnorf', 'gnarble gnarf' end end end
Version data entries
16 entries across 16 versions & 1 rubygems