Sha256: 633f9841c3ca169a5aa66addc7c4a4032a25723dcf8620666eb02cd30c9543e8

Contents?: true

Size: 701 Bytes

Versions: 3

Compression:

Stored size: 701 Bytes

Contents

$:.unshift File.dirname(__FILE__) + '/../lib'

require 'fabric'
require 'fabric-test'

begin
  require 'database_cleaner'
rescue LoadError
  abort 'Database Cleaner is required to run specs - gem install database_cleaner'
end

TEST_SERVER = Fabric::Test.settings['server']
TEST_RUNNER = Fabric::Test.settings['runner']
TEST_USER = Fabric::Test.settings['user']
TEST_DOOMED_USER = Fabric::Test.settings['doomed_user']
TEST_GROUP = Fabric::Test.settings['group']

Spec::Runner.configure do |config|
  config.before(:suite) do 
    DatabaseCleaner.strategy = :transaction
  end 

  config.before(:each) do 
    DatabaseCleaner.start 
  end 

  config.after(:each) do 
    DatabaseCleaner.clean 
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fabric-0.4.1 spec/spec_helper.rb
fabric-0.4.0 spec/spec_helper.rb
fabric-0.3.6 spec/spec_helper.rb