<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="http://localhost/" />
<title>CreateModifyRole</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">CreateModifyRole</td></tr>
</thead><tbody>
<tr>
    <td>setTimeout</td>
    <td>45000</td>
    <td></td>
</tr>
<tr>
  <td>store</td>
  <td>javascript{Math.floor(Math.random()*11000)}</td>
  <td>randomSuffix</td>
</tr>
<tr>
  <td>store</td>
  <td>javascript{Math.floor(Math.random()*11000)}</td>
  <td>randomSuffix2</td>
</tr>
<tr>
  <td>open</td>
  <td>index.php/configuration</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>Roles</td>
  <td></td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>Manage Roles</td>
  <td></td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>//div[@id='ConfigureModulesMenuView']/ul/li[12]/a/span</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>//div[@id='ActionBarForRolesTreeListView']/div/div/a</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>type</td>
  <td>Role_name</td>
  <td>testRole${randomSuffix}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>save</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>waitForTextPresent</td>
  <td>Roles Home</td>
  <td></td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>testRole${randomSuffix}</td>
  <td></td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=testRole${randomSuffix}</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertValue</td>
  <td>Role_name</td>
  <td>testRole${randomSuffix}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=Cancel</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>Roles Home</td>
  <td></td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>//div[@id='ActionBarForRolesTreeListView']/div/div/a</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>type</td>
  <td>Role_name</td>
  <td>testRole${randomSuffix2}</td>
</tr>
<tr>
  <td>click</td>
  <td>Role_role_SelectLink</td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>waitForTextPresent</td>
  <td>Select a Parent Role</td>
  <td></td>
</tr>
<tr>
  <td>click</td>
  <td>link=testRole${randomSuffix}</td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>waitForValue</td>
  <td>Role_role_name</td>
  <td>testRole${randomSuffix}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>save</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>waitForTextPresent</td>
  <td>Roles Home</td>
  <td></td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>Roles Home</td>
  <td></td>
</tr>
<tr>
  <td>assertText</td>
  <td>link=testRole${randomSuffix}</td>
  <td>testRole${randomSuffix}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=testRole${randomSuffix2}</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertValue</td>
  <td>Role_name</td>
  <td>testRole${randomSuffix2}</td>
</tr>
<tr>
  <td>assertValue</td>
  <td>Role_role_name</td>
  <td>testRole${randomSuffix}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>save</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<!-- Create a User -->
<tr>
  <td>open</td>
  <td>index.php/configuration</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>Users - Manage Users</td>
  <td></td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>//div[@id='ConfigureModulesMenuView']/ul/li[13]/a/span</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>//div[@id='UsersActionBarForSearchAndListView']/div/div/a[1]</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>select</td>
  <td>UserPasswordForm_title_value</td>
  <td>label=Mr.</td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>type</td>
  <td>UserPasswordForm_firstName</td>
  <td>Jhon</td>
</tr>
<tr>
  <td>type</td>
  <td>UserPasswordForm_lastName</td>
  <td>Smith${randomSuffix}</td>
</tr>
<tr>
  <td>type</td>
  <td>UserPasswordForm_username</td>
  <td>jhon smith${randomSuffix}</td>
</tr>
<tr>
  <td>type</td>
  <td>UserPasswordForm_newPassword</td>
  <td>abc123</td>
</tr>
<tr>
  <td>type</td>
  <td>UserPasswordForm_newPassword_repeat</td>
  <td>abc123</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>save</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>click</td>
  <td>//div[@id='UserDetailsView']/div/a</td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertText</td>
  <td>link=Edit</td>
  <td>Edit</td>
</tr>
<tr>
  <td>assertText</td>
  <td>//div[@id='zurmoView']/div[1]/table/tbody/tr[6]/td</td>
  <td>jhon smith${randomSuffix}</td>
</tr>
<!-- Create of a User completes here-->
<tr>
  <td>open</td>
  <td>index.php/users/default</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<!-- Search for a user -->
<tr>
  <td>verifyTextPresent</td>
  <td>Advanced</td>
  <td></td>
</tr>
<tr>
  <td>type</td>
  <td>UsersSearchForm_anyMixedAttributes</td>
  <td>jhon smith${randomSuffix}</td>
</tr>
<tr>
  <td>keyUp</td>
  <td>UsersSearchForm_anyMixedAttributes</td>
  <td>\10</td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>waitForTextPresent</td>
  <td>Jhon Smith${randomSuffix}</td>
  <td></td>
</tr>
<tr>
  <td>assertText</td>
  <td>link=Jhon Smith${randomSuffix}</td>
  <td>Jhon Smith${randomSuffix}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=Jhon Smith${randomSuffix}</td>
  <td></td>
</tr>
<!-- Search for a user ends here-->
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertText</td>
  <td>//div[@id='zurmoView']/div[1]/table/tbody/tr[2]/th</td>
  <td>Department</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=Edit</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>click</td>
  <td>User_role_SelectLink</td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>waitForTextPresent</td>
  <td>Select a Role</td>
  <td></td>
</tr>
<tr>
  <td>click</td>
  <td>link=testRole${randomSuffix2}</td>
  <td></td>
</tr>
<tr>
  <td>waitForValue</td>
  <td>User_role_name</td>
  <td>testRole${randomSuffix2}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>save</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertText</td>
  <td>//div[@id='zurmoView']/div[2]/table/tbody/tr[1]/td/a</td>
  <td>testRole${randomSuffix2}</td>
</tr>
<tr>
  <td>open</td>
  <td>index.php/zurmo/role</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=testRole${randomSuffix}</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>click</td>
  <td>link=Delete Role</td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertConfirmation</td>
  <td>Are you sure you want to delete this role?</td>
  <td></td>
</tr>
<tr>
  <td>chooseOkOnNextConfirmationAndWait</td>
  <td></td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>Roles Home </td>
  <td></td>
</tr>
<tr>
  <td>assertTextNotPresent</td>
  <td>link=testRole${randomSuffix}</td>
  <td></td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=testRole${randomSuffix2}</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertValue</td>
  <td>Role_role_name</td>
  <td></td>
</tr>
<tr>
  <td>click</td>
  <td>link=Delete Role</td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertConfirmation</td>
  <td>Are you sure you want to delete this role?</td>
  <td></td>
</tr>
<tr>
  <td>chooseOkOnNextConfirmationAndWait</td>
  <td></td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertTextPresent</td>
  <td>Roles Home </td>
  <td></td>
</tr>
<tr>
  <td>assertTextNotPresent</td>
  <td>link=testRole${randomSuffix2}</td>
  <td></td>
</tr>
<tr>
  <td>open</td>
  <td>index.php/users/default</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>type</td>
  <td>UsersSearchForm_anyMixedAttributes</td>
  <td>Jhon Smith${randomSuffix}</td>
</tr>
<tr>
  <td>keyUp</td>
  <td>UsersSearchForm_anyMixedAttributes</td>
  <td>\10</td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>waitForTextPresent</td>
  <td>Jhon Smith${randomSuffix}</td>
  <td></td>
</tr>
<tr>
  <td>assertText</td>
  <td>link=Jhon Smith${randomSuffix}</td>
  <td>Jhon Smith${randomSuffix}</td>
</tr>
<tr>
  <td>clickAndWait</td>
  <td>link=Jhon Smith${randomSuffix}</td>
  <td></td>
</tr>
<tr>
  <td>waitForPageToLoad</td>
  <td></td>
  <td></td>
</tr>
<tr>
    <td>waitForCondition</td>
    <td>selenium.browserbot.getCurrentWindow().jQuery.active == 0</td>
    <td>30000</td>
</tr>
<tr>
  <td>assertText</td>
  <td>//div[@id='zurmoView']/div[1]/table/tbody/tr[2]/th</td>
  <td>Department</td>
</tr>
</tr>
</tbody></table>
</body>
</html>