Sha256: 06b3f8c2f9c6a02a376ea712cdb2d42bd3613394a806059691d2200cb849cc92

Contents?: true

Size: 453 Bytes

Versions: 8

Compression:

Stored size: 453 Bytes

Contents

require "spec_helper"

describe Relevance::Tarantula do
  include Relevance::Tarantula
  attr_accessor :verbose
  
  it "writes to stdout if verbose" do
    self.verbose = true
    expects(:puts).with("foo")
    log("foo")
  end

  it "swallows output if !verbose" do
    self.verbose = false
    expects(:puts).never
    log("foo")
  end
  
  it "puts RAILS_ROOT behind a method call" do
    lambda{rails_root}.should raise_error(NameError)
  end
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
codez-tarantula-0.5.1 spec/relevance/tarantula_spec.rb
codez-tarantula-0.5.0 spec/relevance/tarantula_spec.rb
tarantula-0.5.1 spec/relevance/tarantula_spec.rb
tarantula-0.5.0 spec/relevance/tarantula_spec.rb
tarantula-0.4.3 spec/relevance/tarantula_spec.rb
tarantula-0.4.2 spec/relevance/tarantula_spec.rb
tarantula-0.4.1 spec/relevance/tarantula_spec.rb
tarantula-0.4.0 spec/relevance/tarantula_spec.rb