1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package edu.sampleu.krad.screenelement;
17
18 import org.junit.Test;
19 import org.kuali.rice.testtools.selenium.AutomatedFunctionalTestUtils;
20 import org.kuali.rice.testtools.selenium.WebDriverLegacyITBase;
21 import org.kuali.rice.testtools.selenium.WebDriverUtils;
22
23
24
25
26 public class IncidentReportAft extends WebDriverLegacyITBase {
27
28
29
30
31 public static final String BOOKMARK_URL ="/kr-krad/uitest?viewId=Travel-testView2&methodToCall=foo";
32
33 @Override
34 protected String getBookmarkUrl() {
35 return BOOKMARK_URL;
36 }
37
38 @Override
39 protected void navigate() throws InterruptedException {
40 waitAndClickKRAD();
41 waitAndClickByLinkText("Incident Report");
42 switchToWindow("Kuali :: Incident Report");
43 }
44
45 private void testIncidentReport() throws Exception{
46 waitForTextPresent("Incident Report");
47 waitForTextPresent("Incident Feedback");
48 waitForTextPresent("The system has encountered an error and is unable to complete your request at this time. Please provide more information regarding this error by completing this Incident Report.");
49 waitForTextPresent("Stacktrace (only in dev mode)");
50 waitForElementPresentByXpath("//button[contains(text(),'Submit Report')]");
51 }
52
53 @Test
54 public void testIncidentReportBookmark() throws Exception {
55 testIncidentReport();
56 passed();
57 }
58
59 @Test
60 public void testIncidentReportNav() throws Exception {
61 testIncidentReport();
62 passed();
63 }
64
65 }