Commit f79e209d authored by Eric Davis's avatar Eric Davis

[#123] Fix hardcoded test value with a dynamic one

parent 0ba4134e
......@@ -239,8 +239,9 @@ class IssueNestedSetTest < ActiveSupport::TestCase
leaf.subject = 'leaf with journal'
leaf.save!
total_journals_on_children = leaf.reload.journals.count + child.reload.journals.count
assert_difference 'Issue.count', -2 do
assert_difference 'IssueJournal.count', -3 do
assert_difference 'IssueJournal.count', -total_journals_on_children do
Issue.find(child.id).destroy
end
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment