create projects as reviewed at creation time

Fixes #1788
This commit is contained in:
Carsten Otto 2015-05-22 23:12:45 +02:00
parent 556c68c2e6
commit 6014ce7a6f
4 changed files with 20 additions and 3 deletions

View file

@ -12,6 +12,12 @@ class ProjectFromTodoTest < ActiveSupport::TestCase
assert_equal project.default_context, todo.context
end
def test_project_is_marked_as_reviewed
todo = todos(:upgrade_rails)
project = ProjectFromTodo.new(todo).create
refute project.needs_review?(users(:admin_user))
end
def test_invalid_project_from_invalid_todo
todo = todos(:upgrade_rails)
todo.description = ""