Fixed a bunch of tests

This commit is contained in:
Eric Allen 2009-10-09 21:27:27 -04:00
parent d9108abe92
commit e32b23c615
7 changed files with 22 additions and 9 deletions

View file

@ -15,6 +15,6 @@ click "edit_icon_todo_15"
wait_for_element_present "show_from_todo_15"
type "show_from_todo_15", ""
click "css=#submit_todo_15"
wait_for_element_present "xpath=//div[@id='p1'] //div[@id='todo_15']"
wait_for_element_present "xpath=//div[@id='p1items'] //div[@id='todo_15']"
assert_not_visible "tickler-empty-nd"
assert_text 'badge_count', '2'

View file

@ -5,5 +5,5 @@ click "edit_icon_todo_15"
wait_for_element_present "show_from_todo_15"
type "show_from_todo_15", ""
click "css=#submit_todo_15"
wait_for_element_present "xpath=//div[@id='p1'] //div[@id='todo_15']"
wait_for_element_present "xpath=//div[@id='p1items'] //div[@id='todo_15']"
wait_for_visible "tickler-empty-nd"

View file

@ -5,7 +5,7 @@ open "/projects/1"
# add new todo
type "todo_description", "a brand new todo"
click "css=#todo-form-new-action .submit_box button"
wait_for_element_present "xpath=//div[@id='p1'] //div[@class='item-container']"
wait_for_element_present "xpath=//div[@id='p1items'] //div[@class='item-container']"
# wait for flash to mention that todo was added and verify existence of new todo
wait_for_visible "flash"

View file

@ -2,9 +2,12 @@ setup :fixtures => :all
login :as => 'admin'
open "/projects/2"
click 'css=.project_settings a'
wait_for_visible "project[default_context_name]"
# change default context
type "project[default_context_name]", "errand"
click "commit"
click "css=.positive"
wait_for_visible "flash"

View file

@ -1,14 +1,18 @@
setup :fixtures => :all
login :as => 'admin'
open '/projects/1'
click 'css=.project_settings a'
wait_for_visible "project[default_context_name]"
assert_checked 'project_state_active'
assert_attribute 'css=#project_status .active span', 'class', 'active_state'
assert_attribute 'css=#project_status .hidden span', 'class', 'inactive_state'
assert_text_present 'This project is active'
assert_text 'badge_count', '2'
click 'project_state_hidden'
wait_for_attribute 'css=#project_status .active span', 'class', 'inactive_state'
wait_for_attribute 'css=#project_status .hidden span', 'class', 'active_state'
click 'css=.positive'
wait_for_text_present 'marked as hidden'
assert_text 'badge_count', '2'
open '/projects/1'
assert_text 'badge_count', '2'
click 'css=.project_settings a'
wait_for_visible 'project_state_hidden'
assert_checked 'project_state_hidden'