Current user should be nil to prevent ActiveJob::DeserializationError errors in tests.

git-svn-id: http://svn.redmine.org/redmine/trunk@17666 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2018-11-29 22:20:14 +00:00
parent 1cadb28a6e
commit 198212f991

View File

@@ -23,6 +23,10 @@ class DocumentTest < ActiveSupport::TestCase
:users, :email_addresses, :members, :member_roles, :roles, :users, :email_addresses, :members, :member_roles, :roles,
:groups_users :groups_users
def setup
User.current = nil
end
def test_create def test_create
doc = Document.new(:project => Project.find(1), :title => 'New document', :category => Enumeration.find_by_name('User documentation')) doc = Document.new(:project => Project.find(1), :title => 'New document', :category => Enumeration.find_by_name('User documentation'))
assert doc.save assert doc.save