Leave seeded achievements alone when truncating

This commit is contained in:
Helge Rausch
2016-02-12 08:33:17 +01:00
parent eb66c2e8bf
commit 5ef97cf43c
2 changed files with 2 additions and 3 deletions

View File

@@ -51,7 +51,7 @@ RSpec.configure do |config|
end
config.before(:example, truncate: true) do
DatabaseCleaner.strategy = :truncation
DatabaseCleaner.strategy = :truncation, { except: %w(achievements) }
end
config.before(:example) do

View File

@@ -42,8 +42,7 @@ class GenotypesControllerTest < ActionController::TestCase
activate_authlogic
@user = FactoryGirl.create(:user)
UserSession.create(@user)
@publishing_award = FactoryGirl.
create(:achievement, award: "Published genotyping")
@publishing_award = Achievement.find_by!(award: 'Published genotyping')
end
should "see the upload form" do