Create Modify Group
setTimeout 45000
store javascript{Math.floor(Math.random()*11000)} randomSuffix
open index.php/configuration
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertTextPresent Users - Manage Users
clickAndWait //div[@id='ConfigureModulesMenuView']/ul/li[18]/a/span
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
clickAndWait //div[@id='UsersActionBarForSearchAndListView']/div/nav/div/a/span
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
select UserPasswordForm_title_value label=Mr.
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
type UserPasswordForm_firstName Jhon
type UserPasswordForm_lastName Smith${randomSuffix}
type UserPasswordForm_username jhon smith${randomSuffix}
type UserPasswordForm_newPassword abc123
type UserPasswordForm_newPassword_repeat abc123
clickAndWait save
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
click //div[@id='UserDetailsView']/div/a
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText //div[@id='zurmoView']/div[1]/table/tbody/tr[6]/td jhon smith${randomSuffix}
open index.php/zurmo/group
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
clickAndWait //div[@id='GroupsActionBarAndTreeListView']/div[1]/div[1]/nav[1]/div/a/span
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
type Group_name TestGroup${randomSuffix}
clickAndWait save
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent TestGroup${randomSuffix}
assertText link=User Membership User Membership
clickAndWait link=User Membership
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
addSelection edit-form_userNonMembershipData label=Jhon Smith${randomSuffix}
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
click yw1moveRight
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
addSelection edit-form_userNonMembershipData label=Sally Smith
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
click yw1moveRight
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
clickAndWait save
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Groups / TestGroup${randomSuffix} / Edit
assertText link=User Membership User Membership
clickAndWait link=User Membership
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Jhon Smith${randomSuffix}
removeSelection edit-form_userMembershipData label=Jhon Smith${randomSuffix}
addSelection edit-form_userMembershipData label=Sally Smith
verifyTextPresent Sally Smith
assertText link=Cancel Cancel
clickAndWait link=Cancel
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText link=Record Permissions Record Permissions
clickAndWait link=Record Permissions
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
select ModulePermissionsForm_AccountsModule__1_value label=All
select ModulePermissionsForm_AccountsModule__2_value label=Owner Only
select ModulePermissionsForm_AccountsModule__4_value label=Owner Only
select ModulePermissionsForm_ContactsModule__1_value label=All
clickAndWait save
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Groups / TestGroup${randomSuffix} / Edit
assertText link=Record Permissions Record Permissions
clickAndWait link=Record Permissions
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertSelectedLabel ModulePermissionsForm_AccountsModule__1_value All
assertSelectedLabel ModulePermissionsForm_AccountsModule__2_value Owner Only
assertSelectedLabel ModulePermissionsForm_AccountsModule__4_value Owner Only
assertSelectedLabel ModulePermissionsForm_ContactsModule__1_value All
assertSelectedLabel ModulePermissionsForm_ContactsModule__2_value Not Set - Ad-hoc / Owner
assertSelectedLabel ModulePermissionsForm_ContactsModule__4_value Not Set - Ad-hoc / Owner
assertText link=Cancel Cancel
clickAndWait link=Cancel
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText link=Module Rights Module Rights
clickAndWait link=Module Rights
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertSelectedLabel RightsForm_AccountsModule__RIGHT_CREATE_ACCOUNTS_value Inherited - Allow
assertSelectedLabel RightsForm_LeadsModule__RIGHT_CREATE_LEADS_value Inherited - Allow
assertSelectedLabel RightsForm_UsersModule__RIGHT_LOGIN_VIA_WEB_value Inherited - Allow
select RightsForm_AccountsModule__RIGHT_CREATE_ACCOUNTS_value label=Allow
select RightsForm_LeadsModule__RIGHT_CREATE_LEADS_value label=Allow
select RightsForm_UsersModule__RIGHT_LOGIN_VIA_WEB_value label=Allow
clickAndWait save
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Groups / TestGroup${randomSuffix} / Edit
assertText link=Module Rights Module Rights
clickAndWait link=Module Rights
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertSelectedLabel RightsForm_AccountsModule__RIGHT_CREATE_ACCOUNTS_value Allow
assertSelectedLabel RightsForm_LeadsModule__RIGHT_CREATE_LEADS_value Allow
assertSelectedLabel RightsForm_ContactsModule__RIGHT_CREATE_CONTACTS_value Inherited - Allow
assertSelectedLabel RightsForm_UsersModule__RIGHT_LOGIN_VIA_WEB_value Allow
assertText link=Cancel Cancel
clickAndWait link=Cancel
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText link=Policies Policies
clickAndWait link=Policies
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertSelectedLabel PoliciesForm_UsersModule__POLICY_ENFORCE_STRONG_PASSWORDS_value Not Set
assertSelectedLabel PoliciesForm_UsersModule__POLICY_MINIMUM_PASSWORD_LENGTH__helper Not Set
assertSelectedLabel PoliciesForm_UsersModule__POLICY_MINIMUM_USERNAME_LENGTH__helper Not Set
assertSelectedLabel PoliciesForm_UsersModule__POLICY_PASSWORD_EXPIRES_value Not Set
select PoliciesForm_UsersModule__POLICY_ENFORCE_STRONG_PASSWORDS_value label=Yes
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
select PoliciesForm_UsersModule__POLICY_MINIMUM_PASSWORD_LENGTH__helper label=Yes
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
select PoliciesForm_UsersModule__POLICY_MINIMUM_USERNAME_LENGTH__helper label=Yes
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
select PoliciesForm_UsersModule__POLICY_PASSWORD_EXPIRES_value label=Yes
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
type PoliciesForm_UsersModule__POLICY_MINIMUM_PASSWORD_LENGTH 5
type PoliciesForm_UsersModule__POLICY_MINIMUM_USERNAME_LENGTH 5
type PoliciesForm_UsersModule__POLICY_PASSWORD_EXPIRES 30
clickAndWait save
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Groups / TestGroup${randomSuffix} / Edit
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText link=Policies Policies
clickAndWait link=Policies
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertSelectedLabel PoliciesForm_UsersModule__POLICY_ENFORCE_STRONG_PASSWORDS_value Yes
assertSelectedLabel PoliciesForm_UsersModule__POLICY_MINIMUM_PASSWORD_LENGTH__helper Yes
assertSelectedLabel PoliciesForm_UsersModule__POLICY_MINIMUM_USERNAME_LENGTH__helper Yes
assertSelectedLabel PoliciesForm_UsersModule__POLICY_PASSWORD_EXPIRES_value Yes
assertValue PoliciesForm_UsersModule__POLICY_PASSWORD_EXPIRES 30
assertValue PoliciesForm_UsersModule__POLICY_MINIMUM_USERNAME_LENGTH 5
assertValue PoliciesForm_UsersModule__POLICY_MINIMUM_PASSWORD_LENGTH 5
open index.php/users/default
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Users
verifyTextPresent Advanced
type UsersSearchForm_anyMixedAttributes jhon smith${randomSuffix}
keyUp UsersSearchForm_anyMixedAttributes \10
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
waitForTextPresent Jhon Smith${randomSuffix}
assertText link=Jhon Smith${randomSuffix} Jhon Smith${randomSuffix}
clickAndWait link=Jhon Smith${randomSuffix}
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText link=Security Overview Security Overview
clickAndWait link=Security Overview
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Groups
verifyTextPresent Group Module Rights
verifyTextPresent Group Policies
verifyTextPresent Group Record Permissions
assertTextPresent Jhon Smith${randomSuffix}
assertText //div[@id='RightsEditAndDetailsView']/div/div/div[1]/table/tbody/tr[1]/td Deny
assertText //div[@id='RightsEditAndDetailsView']/div/div/div[2]/table/tbody/tr[1]/td Deny
assertText //div[@id='RightsEditAndDetailsView']/div/div/div[4]/table/tbody/tr[1]/td Allow
assertText //div[@id='PoliciesEditAndDetailsView']/div/div/div/table/tbody/tr[1]/td Yes
assertText //div[@id='PoliciesEditAndDetailsView']/div/div/div/table/tbody/tr[2]/td 5
assertText //div[@id='PoliciesEditAndDetailsView']/div/div/div/table/tbody/tr[3]/td 5
assertText //div[@id='PoliciesEditAndDetailsView']/div/div/div/table/tbody/tr[4]/td Yes, every 30 day(s)
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[2]/td[1] All
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[3]/td[1] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[4]/td[1] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[2]/td[2] Owner Only
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[3]/td[2] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[2]/td[3] Owner Only
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[3]/td[3] Ad-hoc / Owner
open index.php/zurmo/group
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
clickAndWait link=TestGroup${randomSuffix} TestGroup${randomSuffix}
clickAndWait link=TestGroup${randomSuffix}
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText link=Delete Group Delete Group
click link=Delete Group
assertConfirmation Are you sure you want to delete this group?
chooseOkOnNextConfirmationAndWait
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
open index.php/users/default
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
verifyTextPresent Advanced
type UsersSearchForm_anyMixedAttributes jhon smith${randomSuffix}
keyUp UsersSearchForm_anyMixedAttributes \10
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
waitForTextPresent Jhon Smith${randomSuffix}
assertText link=Jhon Smith${randomSuffix} Jhon Smith${randomSuffix}
clickAndWait link=Jhon Smith${randomSuffix}
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertText link=Security Overview Security Overview
clickAndWait link=Security Overview
waitForPageToLoad
waitForCondition selenium.browserbot.getCurrentWindow().jQuery.active == 0 30000
assertTextNotPresent TestGroup${randomSuffix}
assertTextPresent Everyone
assertText //div[@id='PoliciesEditAndDetailsView']/div/div/div/table/tbody/tr[1]/td No
assertText //div[@id='PoliciesEditAndDetailsView']/div/div/div/table/tbody/tr[4]/td No
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[2]/td[1] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[3]/td[1] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[4]/td[1] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[2]/td[2] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[3]/td[2] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[4]/td[2] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[2]/td[3] Ad-hoc / Owner
assertText //div[@id='ModulePermissionsEditAndDetailsView']/div/div/table/tbody/tr[3]/td[3] Ad-hoc / Owner
assertText //div[@id='RightsEditAndDetailsView']/div/div/div[1]/table/tbody/tr[1]/td Deny
assertText //div[@id='RightsEditAndDetailsView']/div/div/div[2]/table/tbody/tr[1]/td Deny
assertText //div[@id='RightsEditAndDetailsView']/div/div/div[4]/table/tbody/tr[1]/td Allow