Revision d2a09415
Added by Andreas Kohlbecker over 8 years ago
modules/cdm_dataportal/test/java/dataportal-selenium-tests/src/test/java/eu/etaxonomy/dataportal/selenium/tests/cyprus/CyprusSearchTest.java | ||
---|---|---|
1 |
// $Id$ |
|
2 |
/** |
|
3 |
* Copyright (C) 2009 EDIT |
|
4 |
* European Distributed Institute of Taxonomy |
|
5 |
* http://www.e-taxonomy.eu |
|
6 |
* |
|
7 |
* The contents of this file are subject to the Mozilla Public License Version 1.1 |
|
8 |
* See LICENSE.TXT at the top of this package for the full license terms. |
|
9 |
*/ |
|
10 |
package eu.etaxonomy.dataportal.selenium.tests.cyprus; |
|
11 |
|
|
12 |
import static org.junit.Assert.assertNull; |
|
13 |
|
|
14 |
import org.junit.Assert; |
|
15 |
import org.junit.Before; |
|
16 |
import org.junit.Ignore; |
|
17 |
import org.junit.Test; |
|
18 |
import org.openqa.selenium.By; |
|
19 |
import org.openqa.selenium.WebElement; |
|
20 |
|
|
21 |
import eu.etaxonomy.dataportal.DataPortalContext; |
|
22 |
import eu.etaxonomy.dataportal.elements.TaxonListElement; |
|
23 |
import eu.etaxonomy.dataportal.junit.CdmDataPortalTestBase; |
|
24 |
import eu.etaxonomy.dataportal.junit.DataPortalContextSuite.DataPortalContexts; |
|
25 |
import eu.etaxonomy.dataportal.pages.GenericPortalPage; |
|
26 |
import eu.etaxonomy.dataportal.pages.TaxonSearchResultPage; |
|
27 |
|
|
28 |
/** |
|
29 |
* @author a.kohlbecker |
|
30 |
* |
|
31 |
*/ |
|
32 |
|
|
33 |
@DataPortalContexts( { DataPortalContext.cyprus }) |
|
34 |
public class CyprusSearchTest extends CdmDataPortalTestBase{ |
|
35 |
|
|
36 |
private GenericPortalPage homePage; |
|
37 |
|
|
38 |
@Before |
|
39 |
public void setUp() throws Exception { |
|
40 |
|
|
41 |
driver.get(getContext().getBaseUri().toString()); |
|
42 |
homePage = new GenericPortalPage(driver, getContext()); |
|
43 |
|
|
44 |
} |
|
45 |
|
|
46 |
/** |
|
47 |
* see http://dev.e-taxonomy.eu/trac/ticket/2350 |
|
48 |
* @throws Exception |
|
49 |
*/ |
|
50 |
@Test |
|
51 |
public void searchResultsWithoutAnnotationFootnotes() throws Exception{ |
|
52 |
|
|
53 |
TaxonSearchResultPage searchResultPage = homePage.submitQuery("Genis*"); |
|
54 |
|
|
55 |
for (TaxonListElement item : searchResultPage.getResultItems()){ |
|
56 |
assertNull("result set entries must not have footnote keys", item.getElement().findElements(By.className("footnote-key"))); |
|
57 |
} |
|
58 |
|
|
59 |
} |
|
60 |
|
|
61 |
} |
|
1 |
// $Id$ |
|
2 |
/** |
|
3 |
* Copyright (C) 2009 EDIT |
|
4 |
* European Distributed Institute of Taxonomy |
|
5 |
* http://www.e-taxonomy.eu |
|
6 |
* |
|
7 |
* The contents of this file are subject to the Mozilla Public License Version 1.1 |
|
8 |
* See LICENSE.TXT at the top of this package for the full license terms. |
|
9 |
*/ |
|
10 |
package eu.etaxonomy.dataportal.selenium.tests.cyprus; |
|
11 |
|
|
12 |
import static org.junit.Assert.assertNull; |
|
13 |
|
|
14 |
import org.junit.Assert; |
|
15 |
import org.junit.Before; |
|
16 |
import org.junit.Ignore; |
|
17 |
import org.junit.Test; |
|
18 |
import org.openqa.selenium.By; |
|
19 |
import org.openqa.selenium.WebElement; |
|
20 |
|
|
21 |
import eu.etaxonomy.dataportal.DataPortalContext; |
|
22 |
import eu.etaxonomy.dataportal.elements.TaxonListElement; |
|
23 |
import eu.etaxonomy.dataportal.junit.CdmDataPortalTestBase; |
|
24 |
import eu.etaxonomy.dataportal.junit.DataPortalContextSuite.DataPortalContexts; |
|
25 |
import eu.etaxonomy.dataportal.pages.GenericPortalPage; |
|
26 |
import eu.etaxonomy.dataportal.pages.TaxonSearchResultPage; |
|
27 |
|
|
28 |
/** |
|
29 |
* @author a.kohlbecker |
|
30 |
* |
|
31 |
*/ |
|
32 |
|
|
33 |
@DataPortalContexts( { DataPortalContext.cyprus }) |
|
34 |
public class CyprusSearchTest extends CdmDataPortalTestBase{ |
|
35 |
|
|
36 |
private GenericPortalPage homePage; |
|
37 |
|
|
38 |
@Before |
|
39 |
public void setUp() throws Exception { |
|
40 |
|
|
41 |
driver.get(getContext().getBaseUri().toString()); |
|
42 |
homePage = new GenericPortalPage(driver, getContext()); |
|
43 |
|
|
44 |
} |
|
45 |
|
|
46 |
/** |
|
47 |
* see http://dev.e-taxonomy.eu/trac/ticket/2350 |
|
48 |
* @throws Exception |
|
49 |
*/ |
|
50 |
@Test |
|
51 |
public void searchResultsWithoutAnnotationFootnotes() throws Exception{ |
|
52 |
|
|
53 |
TaxonSearchResultPage searchResultPage = homePage.submitQuery("Genis*"); |
|
54 |
|
|
55 |
for (TaxonListElement item : searchResultPage.getResultItems()){ |
|
56 |
assertNull("result set entries must not have footnote keys", item.getElement().findElements(By.className("footnote-key"))); |
|
57 |
} |
|
58 |
|
|
59 |
} |
|
60 |
|
|
61 |
} |
Also available in: Unified diff
CRLF will be replaced by LF issues