1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.krad.labs;
17
18 import org.junit.Test;
19 import org.kuali.rice.testtools.selenium.WebDriverLegacyITBase;
20
21
22
23
24 public class LabsQuickFinderCallbackAft extends WebDriverLegacyITBase {
25
26
27
28
29 public static final String BOOKMARK_URL = "/kr-krad/quickfinder?viewId=Lab-QuickFinderCallback";
30
31 @Override
32 protected String getBookmarkUrl() {
33 return BOOKMARK_URL;
34 }
35
36 @Override
37 protected void navigate() throws Exception {
38 waitAndClickByLinkText("QuickFinder Callback");
39 }
40
41 protected void testDemoQuickFinderCallback() throws Exception {
42 waitAndClickByXpath("//section[@id='Lab-QuickFinder-Table5']/div/table/tbody/tr/td[3]/div/div/div/button");
43 testLookUpSearchReturn();
44 waitAndClickByXpath("//section[@id='Lab-QuickFinder-Table4']/div/table/tbody/tr/td[3]/div/div/div/button");
45 testLookUpSearchReturn();
46 waitAndClickByXpath("//section[@id='Lab-QuickFinder-Table3']/div/table/tbody/tr/td[3]/div/div/div/button");
47 testLookUpSearchReturn();
48 waitAndClickByXpath("//section[@id='Lab-QuickFinder-Grid1']/table/tbody/tr/td/div/div/div/button");
49 testLookUpSearchReturn();
50 waitAndClickByXpath("//section[@id='Lab-QuickFinder-Table1']/div/table/tbody/tr/td[3]/div/div/div/button");
51 testLookUpSearchReturn();
52 waitAndClickByXpath("//section[@id='Lab-QuickFinder-Table2']/div/table/tbody/tr/td[3]/div/div/div/button");
53 testLookUpSearchReturn();
54 }
55
56 private void testLookUpSearchReturn() throws Exception {
57 gotoLightBox();
58 waitAndClickButtonByExactText("Search");
59 waitAndClickByLinkText("return value");
60 }
61
62 @Test
63 public void testDemoQuickFinderCallbackBookmark() throws Exception {
64 testDemoQuickFinderCallback();
65 passed();
66 }
67
68 @Test
69 public void testDemoQuickFinderCallbackNav() throws Exception {
70 testDemoQuickFinderCallback();
71 passed();
72 }
73 }