AddEducationBackground
comment Validate Educational Background Form
deleteAllVisibleCookies
setTimeout 100000
open /vivo/
assertTitle VIVO
comment Must not be logged in already
clickAndWait link=Log in
assertTitle VIVO Site Administration
comment Must log in as site admin
type loginName testAdmin
type loginPassword Password
clickAndWait loginForm
assertTitle VIVO Site Administration
comment Navigate to Jane Faculty via Index
clickAndWait link=Index
assertTitle Index to VIVO Contents
clickAndWait link=Faculty Member
assertTitle Faculty Member
clickAndWait link=Jane Faculty
assertTitle Jane Faculty
clickAndWait //div[@id='educationalTraining']/a
assertTitle Edit
comment Cancel out of form
clickAndWait link=Cancel
assertTitle Jane Faculty
clickAndWait //div[@id='educationalTraining']/a
comment Verify entering no fields results in error
clickAndWait submit
assertTitle Edit
verifyTextPresent This field must not be empty.
verifyTextPresent Must either select an existing organization or create a new one.
comment Verify entering just degree is not valid
select degreeUri label=B.S. Bachelor of Science
clickAndWait submit
assertTitle Edit
verifyTextPresent This field must not be empty.
verifyTextPresent Must either select an existing organization or create a new one.
comment Verify entering just degree and major is not valid
select degreeUri label=B.S. Bachelor of Science
type majorField Business Administration
clickAndWait submit
assertTitle Edit
verifyTextPresent Must either select an existing organization or create a new one.
comment Verify organization must be selected or entered
select degreeUri label=B.S. Bachelor of Science
type majorField Business Administration
comment For now 9999 is a valid year
type year 1980
clickAndWait submit
assertTitle Edit
verifyTextPresent Must either select an existing organization or create a new one.
comment Select to add new organization but cancel before doing so
click link=add a new organization
click link=cancel
comment Select to add new organization but leave field blank
click link=add a new organization
clickAndWait submit
assertTitle Edit
verifyTextPresent Must specify an organization.
click link=add a new organization
comment Enter in new organization name but leave type blank
type newOrgName Carroll College
clickAndWait submit
assertTitle Edit
verifyTextPresent Must select a type for the new organization.
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
comment Enter everything in correctly
select newOrgType label=College
clickAndWait submit
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
comment Verify degree appears
assertTitle Jane Faculty
verifyTextPresent B.S. Bachelor of Science in Business Administration, Carroll College, 1980
clickAndWait //div[@id='educationalTraining']/a
assertTitle Edit
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
comment Add degree from existing organization
select degreeUri label=M.B.A. Master of Business Administration
type majorField Business Administration
type year 2000
select organizationUri label=Carroll College
type dept Business Department
clickAndWait submit
comment Verify both degrees appear
assertTitle Jane Faculty
verifyTextPresent B.S. Bachelor of Science in Business Administration, Carroll College, 1980
verifyTextPresent M.B.A. Master of Business Administration in Business Administration, Carroll College, Business Department, 2000
comment Add third degree from new organization
clickAndWait //div[@id='educationalTraining']/a
assertTitle Edit
select degreeUri label=M.Ed. Master of Education
type majorField Business Education
type year 2005
click link=add a new organization
type newOrgName University of Wisconsin
select newOrgType label=University
type info Graduate School Fellowship
clickAndWait submit
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
refreshAndWait 10000
comment Verify all 3 degress show up
assertTitle Jane Faculty
verifyTextPresent M.Ed. Master of Education in Business Education, University of Wisconsin, 2005, Graduate School Fellowship
verifyTextPresent B.S. Bachelor of Science in Business Administration, Carroll College, 1980
verifyTextPresent M.B.A. Master of Business Administration in Business Administration, Carroll College, Business Department, 2000
comment Log out
clickAndWait link=Log out
assertTitle VIVO