001/* 002 * (C) Copyright 2011 Nuxeo SA (http://nuxeo.com/) and others. 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 * 016 * Contributors: 017 * Sun Seng David TAN <[email protected]> 018 */ 019package org.nuxeo.functionaltests.pages.tabs; 020 021import org.nuxeo.functionaltests.pages.DocumentBasePage; 022import org.openqa.selenium.WebDriver; 023import org.openqa.selenium.WebElement; 024import org.openqa.selenium.support.FindBy; 025 026/** 027 * @author Sun Seng David TAN <[email protected]> 028 */ 029public class ManageTabSubPage extends DocumentBasePage { 030 031 @FindBy(xpath = "//a[contains(@id,'nxw_TAB_RIGHTS')]/span") 032 WebElement accessRightsLink; 033 034 @FindBy(xpath = "//a[contains(@id,'nxw_TAB_TRASH_CONTENT')]/span") 035 WebElement trashLink; 036 037 @FindBy(xpath = "//a[contains(@id,'nxw_TAB_LOCAL_CONFIGURATION')]/span") 038 WebElement localConfigLink; 039 040 public ManageTabSubPage(WebDriver driver) { 041 super(driver); 042 } 043 044 /** 045 * @deprecated since 7.10. Use {@link PermissionsSubPage} instead. 046 * @return 047 */ 048 @Deprecated 049 public AccessRightsSubPage getAccessRightsSubTab() { 050 clickOnDocumentTabLink(accessRightsLink); 051 return asPage(AccessRightsSubPage.class); 052 } 053 054 public TrashSubPage getTrashSubTab() { 055 clickOnDocumentTabLink(trashLink); 056 return asPage(TrashSubPage.class); 057 } 058 059 /** 060 * @since 8.3 061 */ 062 public LocalConfigSubPage getLocalConfigSubTab() { 063 clickOnDocumentTabLink(localConfigLink); 064 return asPage(LocalConfigSubPage.class); 065 } 066 067}