rewrite project commits features using spinach
This commit is contained in:
parent
7aeb92b8e4
commit
080bd12e16
24 changed files with 178 additions and 20 deletions
|
@ -4,12 +4,21 @@ require './config/environment'
|
|||
require 'rspec'
|
||||
require 'database_cleaner'
|
||||
|
||||
%w(login_helpers stubbed_repository).each do |f|
|
||||
%w(gitolite_stub login_helpers stubbed_repository valid_commit).each do |f|
|
||||
require Rails.root.join('spec', 'support', f)
|
||||
end
|
||||
|
||||
include LoginHelpers
|
||||
include GitoliteStub
|
||||
|
||||
DatabaseCleaner.strategy = :transaction
|
||||
WebMock.allow_net_connect!
|
||||
|
||||
DatabaseCleaner.strategy = :truncation
|
||||
Spinach.hooks.before_scenario { DatabaseCleaner.start }
|
||||
Spinach.hooks.after_scenario { DatabaseCleaner.clean }
|
||||
|
||||
Spinach.hooks.before_run do
|
||||
RSpec::Mocks::setup self
|
||||
|
||||
stub_gitolite!
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue