Sha256: 146f7cfb1d6e511416e6123fd77bc797295dd2047fff035e665ec7c37236857a

Contents?: true

Size: 977 Bytes

Versions: 7

Compression:

Stored size: 977 Bytes

Contents

# Sets up the Merb environment for Cucumber (thanks to krzys and roman)
require "rubygems"

# Add the local gems dir if found within the app root; any dependencies loaded
# hereafter will try to load from the local gems before loading system gems.
if (local_gem_dir = File.join(File.dirname(__FILE__), '..', 'gems')) && $BUNDLE.nil?
  $BUNDLE = true; Gem.clear_paths; Gem.path.unshift(local_gem_dir)
end

require "merb-core"
require "spec"
require "merb_cucumber/world/<%= session_type %>"
<% if orm == :datamapper -%>
require "merb_cucumber/helpers/datamapper"
<% elsif orm == :activerecord -%>
require "merb_cucumber/helpers/activerecord"
<% end -%>

# Uncomment if you want transactional fixtures
# Merb::Test::World::Base.use_transactional_fixtures

# Quick fix for post features running Rspec error, see 
# http://gist.github.com/37930
def Spec.run? ; true; end

Merb.start_environment(:testing => true, :adapter => 'runner', :environment => ENV['MERB_ENV'] || 'test')
  

Version data entries

7 entries across 7 versions & 3 rubygems

Version Path
david-merb_cucumber-0.5.0.1 lib/generators/cucumber/templates/features/support/env.rb
david-merb_cucumber-0.5.0 lib/generators/cucumber/templates/features/support/env.rb
david-merb_cucumber-0.5.1.1 lib/generators/cucumber/templates/features/support/env.rb
david-merb_cucumber-0.5.1.2 lib/generators/cucumber/templates/features/support/env.rb
david-merb_cucumber-0.5.1 lib/generators/cucumber/templates/features/support/env.rb
jsmestad-merb_cucumber-0.5.1.3 lib/generators/cucumber/templates/features/support/env.rb
roman-merb_cucumber-0.5.1.3 lib/generators/cucumber/templates/features/support/env.rb