diff test/functional/gantts_controller_test.rb @ 38:33d69fee1d99 cannam

* Merge SVN update from default branch
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Fri, 19 Nov 2010 13:41:40 +0000
parents 94944d00e43c
children af80e5618e9b
line wrap: on
line diff
--- a/test/functional/gantts_controller_test.rb	Fri Oct 01 15:33:14 2010 +0100
+++ b/test/functional/gantts_controller_test.rb	Fri Nov 19 13:41:40 2010 +0000
@@ -20,6 +20,25 @@
       i = Issue.find(2)
       assert_select "div a.issue", /##{i.id}/
     end
+    
+    should "work without issue due dates" do
+      Issue.update_all("due_date = NULL")
+      
+      get :show, :project_id => 1
+      assert_response :success
+      assert_template 'show.html.erb'
+      assert_not_nil assigns(:gantt)
+    end
+    
+    should "work without issue and version due dates" do
+      Issue.update_all("due_date = NULL")
+      Version.update_all("effective_date = NULL")
+      
+      get :show, :project_id => 1
+      assert_response :success
+      assert_template 'show.html.erb'
+      assert_not_nil assigns(:gantt)
+    end
 
     should "work cross project" do
       get :show