mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-19 00:30:12 +01:00
migrating to aasm - code part
This commit is contained in:
parent
65e3a8ff30
commit
00819ce27b
54 changed files with 2656 additions and 839 deletions
|
|
@ -58,7 +58,7 @@ class ProjectsControllerTest < TodoContainerControllerTestBase
|
|||
login_as(:admin_user)
|
||||
xhr :post, :update, :id => 1, "project"=>{"name"=>p.name, "description"=>p.description, "state"=>"hidden"}
|
||||
todos.each do |t|
|
||||
assert_equal :project_hidden, t.reload().current_state
|
||||
assert_equal :project_hidden, t.reload().aasm_current_state
|
||||
end
|
||||
assert p.reload().hidden?
|
||||
end
|
||||
|
|
@ -70,7 +70,7 @@ class ProjectsControllerTest < TodoContainerControllerTestBase
|
|||
xhr :post, :update, :id => 1, "project"=>{"name"=>p.name, "description"=>p.description, "state"=>"hidden"}
|
||||
xhr :post, :update, :id => 1, "project"=>{"name"=>p.name, "description"=>p.description, "state"=>"active"}
|
||||
todos.each do |t|
|
||||
assert_equal :active, t.reload().current_state
|
||||
assert_equal :active, t.reload().aasm_current_state
|
||||
end
|
||||
assert p.reload().active?
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue