Sha256: 838c302856a8e7ba4594b00e42c994a84531edce58464cd6daf75f379a3ee959

Contents?: true

Size: 266 Bytes

Versions: 3

Compression:

Stored size: 266 Bytes

Contents

module RailsStubs
  # Setup fake `Rails.root`
  def stub_rails_root(path='./spec/fixtures')
    Rails.stub(:root).and_return(Pathname.new(path))
  end

  # Setup fake `Rails.env`
  def stub_rails_env(env='development')
    Rails.stub(:env).and_return(env)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
sprig-reap-0.0.3 spec/support/rails_stubs.rb
sprig-reap-0.0.2 spec/support/rails_stubs.rb
sprig-reap-0.0.1 spec/support/rails_stubs.rb