diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-04-22 11:56:47 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2012-04-22 11:56:47 +0000 |
commit | b960470d7817843906d42628d8bb4228ee49b2d9 (patch) | |
tree | 9c16e3fe4ae68e36e4d3c6c0dfebb267eab9a774 /test/unit/project_test.rb | |
parent | 4a3f038595922dc5fef9f3541363a16078a5ace9 (diff) | |
download | redmine-b960470d7817843906d42628d8bb4228ee49b2d9.tar.gz redmine-b960470d7817843906d42628d8bb4228ee49b2d9.zip |
Removed object_daddy dependency.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9469 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit/project_test.rb')
-rw-r--r-- | test/unit/project_test.rb | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/test/unit/project_test.rb b/test/unit/project_test.rb index 6613ef0b2..fa0b908c1 100644 --- a/test/unit/project_test.rb +++ b/test/unit/project_test.rb @@ -742,7 +742,7 @@ class ProjectTest < ActiveSupport::TestCase project = Project.find(1) system_activity = TimeEntryActivity.find_by_name('Design') assert system_activity.active? - overridden_activity = TimeEntryActivity.generate!(:project => project, :parent => system_activity, :active => false) + overridden_activity = TimeEntryActivity.create!(:name => "Project", :project => project, :parent => system_activity, :active => false) assert overridden_activity.save! assert !project.activities.include?(overridden_activity), "Inactive Project specific Activity not found" @@ -822,10 +822,10 @@ class ProjectTest < ActiveSupport::TestCase :tracker_id => 1, :assigned_to_id => 2, :project_id => @source_project.id) - source_relation = IssueRelation.generate!(:issue_from => Issue.find(4), + source_relation = IssueRelation.create!(:issue_from => Issue.find(4), :issue_to => second_issue, :relation_type => "relates") - source_relation_cross_project = IssueRelation.generate!(:issue_from => Issue.find(1), + source_relation_cross_project = IssueRelation.create!(:issue_from => Issue.find(1), :issue_to => second_issue, :relation_type => "duplicates") @@ -1104,22 +1104,22 @@ class ProjectTest < ActiveSupport::TestCase @role = Role.generate! @user_with_membership_notification = User.generate!(:mail_notification => 'selected') - Member.generate!(:project => @project, :roles => [@role], :principal => @user_with_membership_notification, :mail_notification => true) + Member.create!(:project => @project, :roles => [@role], :principal => @user_with_membership_notification, :mail_notification => true) @all_events_user = User.generate!(:mail_notification => 'all') - Member.generate!(:project => @project, :roles => [@role], :principal => @all_events_user) + Member.create!(:project => @project, :roles => [@role], :principal => @all_events_user) @no_events_user = User.generate!(:mail_notification => 'none') - Member.generate!(:project => @project, :roles => [@role], :principal => @no_events_user) + Member.create!(:project => @project, :roles => [@role], :principal => @no_events_user) @only_my_events_user = User.generate!(:mail_notification => 'only_my_events') - Member.generate!(:project => @project, :roles => [@role], :principal => @only_my_events_user) + Member.create!(:project => @project, :roles => [@role], :principal => @only_my_events_user) @only_assigned_user = User.generate!(:mail_notification => 'only_assigned') - Member.generate!(:project => @project, :roles => [@role], :principal => @only_assigned_user) + Member.create!(:project => @project, :roles => [@role], :principal => @only_assigned_user) @only_owned_user = User.generate!(:mail_notification => 'only_owner') - Member.generate!(:project => @project, :roles => [@role], :principal => @only_owned_user) + Member.create!(:project => @project, :roles => [@role], :principal => @only_owned_user) end should "include members with a mail notification" do |