From 391d5af18d4ccf1c9ae0fe9485c68803d55126e2 Mon Sep 17 00:00:00 2001 From: Vokhmin Alexey V Date: Thu, 27 Jun 2013 23:10:11 +0400 Subject: [PATCH] #200: fixed specs --- spec/lib/observers/activity_feed/comment_spec.rb | 2 -- spec/lib/observers/activity_feed/issue_spec.rb | 2 -- spec/models/comment_for_commit_spec.rb | 1 + spec/models/comment_spec.rb | 1 + spec/models/issue_spec.rb | 1 + spec/spec_helper.rb | 1 + 6 files changed, 4 insertions(+), 4 deletions(-) diff --git a/spec/lib/observers/activity_feed/comment_spec.rb b/spec/lib/observers/activity_feed/comment_spec.rb index 1c027a3e3..84b5065d5 100644 --- a/spec/lib/observers/activity_feed/comment_spec.rb +++ b/spec/lib/observers/activity_feed/comment_spec.rb @@ -11,6 +11,4 @@ describe Modules::Observers::ActivityFeed::Comment do mock(UserMailer).new_comment_notification(comment, comment.commentable.assignee) { mailer } comment.save end - - before(:all) { User.destroy_all } end diff --git a/spec/lib/observers/activity_feed/issue_spec.rb b/spec/lib/observers/activity_feed/issue_spec.rb index f67179655..be287e73b 100644 --- a/spec/lib/observers/activity_feed/issue_spec.rb +++ b/spec/lib/observers/activity_feed/issue_spec.rb @@ -27,6 +27,4 @@ describe Modules::Observers::ActivityFeed::Issue do mock(UserMailer).issue_assign_notification(issue, user) { mailer } issue.save end - - before(:all) { User.destroy_all } end diff --git a/spec/models/comment_for_commit_spec.rb b/spec/models/comment_for_commit_spec.rb index 9972a699a..1d779ef0d 100644 --- a/spec/models/comment_for_commit_spec.rb +++ b/spec/models/comment_for_commit_spec.rb @@ -37,6 +37,7 @@ def should_not_send_email(args={}) end describe Comment do + self.use_transactional_fixtures = false before { stub_symlink_methods } context 'for global admin user' do before(:each) do diff --git a/spec/models/comment_spec.rb b/spec/models/comment_spec.rb index 2226a8c13..51b7eb5a9 100644 --- a/spec/models/comment_spec.rb +++ b/spec/models/comment_spec.rb @@ -19,6 +19,7 @@ def create_comment_in_issue issue, body end describe Comment do + self.use_transactional_fixtures = false before { stub_symlink_methods } context 'for global admin user' do before(:each) do diff --git a/spec/models/issue_spec.rb b/spec/models/issue_spec.rb index 1777fcc92..a8635a625 100644 --- a/spec/models/issue_spec.rb +++ b/spec/models/issue_spec.rb @@ -13,6 +13,7 @@ def create_issue issue_owner end describe Issue do + self.use_transactional_fixtures = false before do stub_symlink_methods any_instance_of(Project, :versions => ['v1.0', 'v2.0']) diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index c233dd750..f5c167bfa 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -30,6 +30,7 @@ RSpec.configure do |config| config.before(:all) { init_test_root } config.after(:all) { clear_test_root } + config.after(:all) { User.destroy_all } end def set_session_for(user=nil)