1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
|
package org.xwiki.administration.test.po; |
21 |
|
|
22 |
|
import java.util.ArrayList; |
23 |
|
import java.util.List; |
24 |
|
|
25 |
|
import org.openqa.selenium.By; |
26 |
|
import org.openqa.selenium.WebElement; |
27 |
|
import org.openqa.selenium.support.FindBy; |
28 |
|
import org.xwiki.test.ui.po.ViewPage; |
29 |
|
|
30 |
|
|
31 |
|
|
32 |
|
|
33 |
|
@since |
34 |
|
@version |
35 |
|
|
|
|
| 0% |
Uncovered Elements: 24 (24) |
Complexity: 7 |
Complexity Density: 0.41 |
|
36 |
|
public class ColorThemePropertyDisplayerPage extends ViewPage |
37 |
|
{ |
38 |
|
|
39 |
|
|
40 |
|
|
41 |
|
@FindBy(id = "${prefix}${name}") |
42 |
|
private WebElement iconThemeInput; |
43 |
|
|
|
|
| 0% |
Uncovered Elements: 2 (2) |
Complexity: 1 |
Complexity Density: 0.5 |
|
44 |
0 |
public static ColorThemePropertyDisplayerPage gotoPage()... |
45 |
|
{ |
46 |
0 |
getUtil().gotoPage("XWiki", "ColorThemePropertyDisplayer"); |
47 |
0 |
return new ColorThemePropertyDisplayerPage(); |
48 |
|
} |
49 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
50 |
0 |
private List<WebElement> getColorThemeOptions()... |
51 |
|
{ |
52 |
0 |
return iconThemeInput.findElements(By.tagName("option")); |
53 |
|
} |
54 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
55 |
0 |
private List<WebElement> getColibriThemeOptions()... |
56 |
|
{ |
57 |
0 |
return iconThemeInput.findElements(By.xpath("//optgroup[@label='Colibri Themes']//option")); |
58 |
|
} |
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
59 |
0 |
private List<WebElement> getFlamingoThemeOptions()... |
60 |
|
{ |
61 |
0 |
return iconThemeInput.findElements(By.xpath("//optgroup[@label='Flamingo Themes']//option")); |
62 |
|
} |
63 |
|
|
64 |
|
|
65 |
|
@return |
66 |
|
|
|
|
| 0% |
Uncovered Elements: 4 (4) |
Complexity: 1 |
Complexity Density: 0.25 |
|
67 |
0 |
public List<String> getColorThemes()... |
68 |
|
{ |
69 |
0 |
List<String> results = new ArrayList<>(); |
70 |
0 |
for (WebElement option : getColorThemeOptions()) { |
71 |
0 |
results.add(option.getText()); |
72 |
|
} |
73 |
0 |
return results; |
74 |
|
} |
75 |
|
|
76 |
|
|
77 |
|
@return |
78 |
|
|
|
|
| 0% |
Uncovered Elements: 4 (4) |
Complexity: 1 |
Complexity Density: 0.25 |
|
79 |
0 |
public List<String> getColibriColorThemes()... |
80 |
|
{ |
81 |
0 |
List<String> results = new ArrayList<>(); |
82 |
0 |
for (WebElement option : getColibriThemeOptions()) { |
83 |
0 |
results.add(option.getText()); |
84 |
|
} |
85 |
0 |
return results; |
86 |
|
} |
87 |
|
|
88 |
|
|
89 |
|
@return |
90 |
|
|
|
|
| 0% |
Uncovered Elements: 4 (4) |
Complexity: 1 |
Complexity Density: 0.25 |
|
91 |
0 |
public List<String> getFlamingoThemes()... |
92 |
|
{ |
93 |
0 |
List<String> results = new ArrayList<>(); |
94 |
0 |
for (WebElement option : getFlamingoThemeOptions()) { |
95 |
0 |
results.add(option.getText()); |
96 |
|
} |
97 |
0 |
return results; |
98 |
|
} |
99 |
|
} |