Skip to content

Commit

Permalink
Set up customer -> project relation
Browse files Browse the repository at this point in the history
git-svn-id: https://dev.abstracture.de/repos/Projects/sas/Hourglass@3674 bfea69f6-0cce-0310-9b16-88a7a1f2502c
  • Loading branch information
sas committed Nov 21, 2008
1 parent 1e998f3 commit d624626
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions Tests/create_document.py
Expand Up @@ -68,11 +68,15 @@ def add_customer(window, name):
row = customer_table(window).rows.last()
update_text_field(row.text_fields[1], name)

def add_project(window, name):
def add_project(window, name, customer):
select_project_group(window)
click_add_project(window)
row = project_table(window).rows.last()
update_text_field(row.text_fields[1], name)
button = window.splitter_groups[1].pop_up_buttons[1]
button.click()
button.menus[1].menu_items[customer].click()
time.sleep(1)


if __name__ == '__main__':
Expand All @@ -90,8 +94,12 @@ def add_project(window, name):
add_customer(doc_window, 'Firm X')
assert customer_table(doc_window).rows.count() == 3

add_project(doc_window, 'Job A')
assert project_table(doc_window).rows.count() == 1
add_project(doc_window, 'Job A', 'Company 3')
add_project(doc_window, 'Project M', 'Firm X')
add_project(doc_window, 'Big Contract', 'Customer D')
add_project(doc_window, 'Internal', 'Firm X')
add_project(doc_window, 'Proj B', 'Company 3')
assert project_table(doc_window).rows.count() == 5

#filemenu.menu_items['New Task'].click()

Expand Down

0 comments on commit d624626

Please sign in to comment.