001 /** 002 * Copyright 2005-2013 The Kuali Foundation 003 * 004 * Licensed under the Educational Community 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.opensource.org/licenses/ecl2.php 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 package edu.sampleu.travel; 017 018 import org.kuali.rice.testtools.common.JiraAwareFailable; 019 import org.kuali.rice.testtools.selenium.WebDriverLegacyITBase; 020 021 /** 022 * Tests the Component section in Rice. 023 * 024 * @author Kuali Rice Team (rice.collab@kuali.org) 025 */ 026 public abstract class ConfigurationTestViewAftBase extends WebDriverLegacyITBase { 027 028 /** 029 * "/kr-krad/configuration-test-view-uif-controller?viewId=ConfigurationTestView&methodToCall=start"; 030 */ 031 public static final String BOOKMARK_URL = "/kr-krad/configuration-test-view-uif-controller?viewId=ConfigurationTestView&methodToCall=start"; 032 033 /** bean id prefix in used in view */ 034 private String idPrefix = "ConfigurationTestView-ProgressiveRender-"; 035 036 /** bean id suffix for add line controls */ 037 String addLineIdSuffix = "InputField_add_control"; 038 039 040 @Override 041 protected String getBookmarkUrl() { 042 return BOOKMARK_URL; 043 } 044 045 protected void navigation() throws InterruptedException { 046 waitAndClickKRAD(); 047 waitAndClickByXpath("(//a[text()='Configuration Test View'])"); 048 switchToWindow(CONFIGURATION_VIEW_WINDOW_TITLE); 049 waitForTitleToEqualKualiPortalIndex(); 050 } 051 052 protected void testConfigurationTestViewNav(JiraAwareFailable failable) throws Exception { 053 navigation(); 054 testConfigurationTestView(idPrefix); 055 testAddLineWithSpecificTime(idPrefix, addLineIdSuffix); 056 testAddLineWithAllDay(idPrefix, addLineIdSuffix); 057 testAddLineAllDay(idPrefix, addLineIdSuffix); 058 passed(); 059 } 060 061 protected void testConfigurationTestViewBookmark(JiraAwareFailable failable) throws Exception { 062 testConfigurationTestView(idPrefix); 063 testAddLineWithSpecificTime(idPrefix, addLineIdSuffix); 064 testAddLineWithAllDay(idPrefix, addLineIdSuffix); 065 testAddLineAllDay(idPrefix, addLineIdSuffix); 066 passed(); 067 } 068 }