Test_SNF_ECMS_64_SetupPreferenceForQuickFilter_ecmdemo
open /ecmdemo/public/acme/
windowMaximize
echo -- Login
click link=Login
waitForElementPresent username
type username root
type password gtn
clickAndWait link=Sign in
echo -- Go to Sites Explorer
clickAndWait //a[@href='/ecmdemo/private/acme/siteExplorer']
echo -- Set up preferences: All Items
waitForElementPresent //div[@id='UIAllItems']/div/div[1]/div/div/div/div[2]
click //div[@id='UIAllItems']/div/div[1]/div/div/div/div[2]
echo --  Hide "Owned by me" field
waitForElementPresent showOwnedByUser
uncheck showOwnedByUser
click link=Save
pause 10000
echo --  Verify showOwnedByUser is hidden
waitForElementNotPresent //div[@id='UIAllItems']//span[text()='Owned by me']
verifyElementNotPresent //div[@id='UIAllItems']//span[text()='Owned by me']
echo --  Show "Owned by me"
waitForElementPresent //div[@id='UIAllItems']/div/div[1]/div/div/div/div[2]
click //div[@id='UIAllItems']/div/div[1]/div/div/div/div[2]
waitForElementPresent showOwnedByUser
check showOwnedByUser
click link=Save
pause 10000
echo --  Verify showOwnedByUser is showed
waitForElementPresent //div[@id='UIAllItems']//span[text()='Owned by me']
verifyElementPresent //div[@id='UIAllItems']//span[text()='Owned by me']
echo --  Set up quick filter by Type
waitForElementPresent //div[@id='UIAllItemsByType']/div/div[1]/div/div/div/div[2]
click //div[@id='UIAllItemsByType']/div/div[1]/div/div/div/div[2]
echo --  Hide Content field
waitForElementPresent Contents
uncheck Contents
click link=Save
pause 10000
echo --  Verify "Contents" is hidden
waitForElementNotPresent //a[contains(text(),'Contents')]
verifyElementNotPresent //a[contains(text(),'Contents')]
echo --  Show Content file
waitForElementPresent //div[@id='UIAllItemsByType']/div/div[1]/div/div/div/div[2]
click //div[@id='UIAllItemsByType']/div/div[1]/div/div/div/div[2]
waitForElementPresent Contents
check Contents
click link=Save
pause 10000
echo --  Verify "Contents" is showed
waitForElementPresent //a[contains(text(),'Contents')]
verifyElementPresent //a[contains(text(),'Contents')]
echo --  Logout
waitForElementPresent link=Sign out
clickAndWait link=Sign out