1. Project Clover database Tue Dec 20 2016 21:24:09 CET
  2. Package org.xwiki.administration.test.po

File AnnotationsPage.java

 

Coverage histogram

../../../../../img/srcFileCovDistChart0.png
83% of files have more coverage

Code metrics

0
9
8
1
92
51
8
0.89
1.12
8
1

Classes

Class Line # Actions
AnnotationsPage 32 9 0% 8 17
0.00%
 

Contributing tests

No tests hitting this source file were found.

Source view

1    /*
2    * See the NOTICE file distributed with this work for additional
3    * information regarding copyright ownership.
4    *
5    * This is free software; you can redistribute it and/or modify it
6    * under the terms of the GNU Lesser General Public License as
7    * published by the Free Software Foundation; either version 2.1 of
8    * the License, or (at your option) any later version.
9    *
10    * This software is distributed in the hope that it will be useful,
11    * but WITHOUT ANY WARRANTY; without even the implied warranty of
12    * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13    * Lesser General Public License for more details.
14    *
15    * You should have received a copy of the GNU Lesser General Public
16    * License along with this software; if not, write to the Free
17    * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18    * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19    */
20    package org.xwiki.administration.test.po;
21   
22    import org.openqa.selenium.WebElement;
23    import org.openqa.selenium.support.FindBy;
24   
25    /**
26    * Represents the actions possible on the Annotations Administration Page.
27    *
28    * @version $Id: 73ed9beada7cc744bfd32a0dccd91042120268dc $
29    * @since 4.2M1
30    */
31   
 
32    public class AnnotationsPage extends AdministrationSectionPage
33    {
34    @FindBy(id = "AnnotationCode.AnnotationConfig_AnnotationCode.AnnotationConfig_0_activated")
35    private WebElement annotationsAreActivatedRadioYes;
36   
37    @FindBy(id = "AnnotationCode.AnnotationConfig_AnnotationCode.AnnotationConfig_0_activated_false")
38    private WebElement annotationsAreActivatedRadioNo;
39   
40    @FindBy(id = "AnnotationCode.AnnotationConfig_AnnotationCode.AnnotationConfig_0_displayed")
41    private WebElement displayAnnotationsByDefaultRadioYes;
42   
43    @FindBy(id = "AnnotationCode.AnnotationConfig_AnnotationCode.AnnotationConfig_0_displayed_false")
44    private WebElement displayAnnotationsByDefaultRadioNo;
45   
46    @FindBy(id = "AnnotationCode.AnnotationConfig_AnnotationCode.AnnotationConfig_0_displayHighlight")
47    private WebElement displayAnnotationsHighlightByDefaultRadioYes;
48   
49    @FindBy(id = "AnnotationCode.AnnotationConfig_AnnotationCode.AnnotationConfig_0_displayHighlight_false")
50    private WebElement displayAnnotationsHighlightByDefaultRadioNo;
51   
 
52  0 toggle public static AnnotationsPage gotoPage()
53    {
54  0 getUtil().gotoPage("XWiki", "XWikiPreferences", "admin", "section=Annotations");
55  0 return new AnnotationsPage();
56    }
57   
 
58  0 toggle public AnnotationsPage()
59    {
60  0 super("Annotations");
61    }
62   
 
63  0 toggle public void activateAnnotations()
64    {
65  0 this.annotationsAreActivatedRadioYes.click();
66    }
67   
 
68  0 toggle public void deactivateAnnotations()
69    {
70  0 this.annotationsAreActivatedRadioNo.click();
71    }
72   
 
73  0 toggle public void displayAnnotationsByDefault()
74    {
75  0 this.displayAnnotationsByDefaultRadioYes.click();
76    }
77   
 
78  0 toggle public void hideAnnotationsByDefault()
79    {
80  0 this.displayAnnotationsByDefaultRadioNo.click();
81    }
82   
 
83  0 toggle public void displayAnnotationsHighlightByDefault()
84    {
85  0 this.displayAnnotationsHighlightByDefaultRadioYes.click();
86    }
87   
 
88  0 toggle public void hideAnnotationsHighlightByDefault()
89    {
90  0 this.displayAnnotationsHighlightByDefaultRadioNo.click();
91    }
92    }