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/Cyprus_HybridTest.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.assertEquals; |
|
13 |
import static org.junit.Assert.assertTrue; |
|
14 |
|
|
15 |
import java.net.MalformedURLException; |
|
16 |
import java.util.UUID; |
|
17 |
|
|
18 |
import org.junit.Test; |
|
19 |
|
|
20 |
import eu.etaxonomy.dataportal.DataPortalContext; |
|
21 |
import eu.etaxonomy.dataportal.elements.ClassificationTreeBlock; |
|
22 |
import eu.etaxonomy.dataportal.elements.ClassificationTreeElement; |
|
23 |
import eu.etaxonomy.dataportal.junit.CdmDataPortalTestBase; |
|
24 |
import eu.etaxonomy.dataportal.junit.DataPortalContextSuite.DataPortalContexts; |
|
25 |
import eu.etaxonomy.dataportal.pages.TaxonProfilePage; |
|
26 |
import eu.etaxonomy.dataportal.pages.TaxonSynonymyPage; |
|
27 |
|
|
28 |
/** |
|
29 |
* |
|
30 |
* @author a.kohlbecker |
|
31 |
* |
|
32 |
*/ |
|
33 |
|
|
34 |
@DataPortalContexts( { DataPortalContext.cyprus }) |
|
35 |
public class Cyprus_HybridTest extends CdmDataPortalTestBase{ |
|
36 |
|
|
37 |
|
|
38 |
static UUID orchiserapias_Uuid = UUID.fromString("0aee7eea-84e7-4b61-8cb6-d17313cc9b80"); |
|
39 |
|
|
40 |
static UUID epilobium_aschersonianum_Uuid = UUID.fromString("e13ea422-5d45-477b-ade3-8dc84dbc9dbc"); |
|
41 |
|
|
42 |
// |
|
43 |
static UUID aegilops_biuncialis_x_geniculata_Uuid = UUID.fromString("88ff0fbb-c0df-46c1-9969-cf318ea97dbb"); |
|
44 |
|
|
45 |
|
|
46 |
@Test |
|
47 |
public void orchiserapias() throws MalformedURLException { |
|
48 |
TaxonSynonymyPage p = new TaxonSynonymyPage(driver, getContext(), orchiserapias_Uuid); |
|
49 |
String expectedName = "×Orchiserapias"; |
|
50 |
assertEquals(getContext().prepareTitle(expectedName), driver.getTitle()); |
|
51 |
assertEquals(expectedName, p.getAcceptedNameText()); |
|
52 |
assertEquals("≡ Orchis × Serapias", p.getHomotypicalGroupSynonymName(1)); |
|
53 |
} |
|
54 |
|
|
55 |
@Test |
|
56 |
public void epilobium_aschersonianum() throws MalformedURLException { |
|
57 |
TaxonSynonymyPage p = new TaxonSynonymyPage(driver, getContext(), epilobium_aschersonianum_Uuid); |
|
58 |
assertEquals(getContext().prepareTitle("Epilobium ×aschersonianum"), driver.getTitle()); |
|
59 |
assertEquals("Epilobium ×aschersonianum Hausskn.", p.getAcceptedNameText()); |
|
60 |
assertEquals("≡ Epilobium lanceolatum × parviflorum", p.getHomotypicalGroupSynonymName(1)); |
|
61 |
} |
|
62 |
|
|
63 |
@Test |
|
64 |
public void aegilops_biuncialis_x_geniculata() throws MalformedURLException { |
|
65 |
TaxonProfilePage p = new TaxonProfilePage(driver, getContext(), aegilops_biuncialis_x_geniculata_Uuid); |
|
66 |
assertEquals(getContext().prepareTitle("Aegilops biuncialis × geniculata"), driver.getTitle()); |
|
67 |
ClassificationTreeBlock classificationTree = p.getClassificationTree(); |
|
68 |
ClassificationTreeElement focusedElement = classificationTree.getFocusedElement(); |
|
69 |
assertTrue(classificationTree.isVisibleInViewPort(focusedElement)); |
|
70 |
assertEquals("Abbreviated form of name should be used", "A. biuncialis × geniculata", focusedElement.getTaxonName()); |
|
71 |
} |
|
72 |
|
|
73 |
} |
|
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.assertEquals; |
|
13 |
import static org.junit.Assert.assertTrue; |
|
14 |
|
|
15 |
import java.net.MalformedURLException; |
|
16 |
import java.util.UUID; |
|
17 |
|
|
18 |
import org.junit.Test; |
|
19 |
|
|
20 |
import eu.etaxonomy.dataportal.DataPortalContext; |
|
21 |
import eu.etaxonomy.dataportal.elements.ClassificationTreeBlock; |
|
22 |
import eu.etaxonomy.dataportal.elements.ClassificationTreeElement; |
|
23 |
import eu.etaxonomy.dataportal.junit.CdmDataPortalTestBase; |
|
24 |
import eu.etaxonomy.dataportal.junit.DataPortalContextSuite.DataPortalContexts; |
|
25 |
import eu.etaxonomy.dataportal.pages.TaxonProfilePage; |
|
26 |
import eu.etaxonomy.dataportal.pages.TaxonSynonymyPage; |
|
27 |
|
|
28 |
/** |
|
29 |
* |
|
30 |
* @author a.kohlbecker |
|
31 |
* |
|
32 |
*/ |
|
33 |
|
|
34 |
@DataPortalContexts( { DataPortalContext.cyprus }) |
|
35 |
public class Cyprus_HybridTest extends CdmDataPortalTestBase{ |
|
36 |
|
|
37 |
|
|
38 |
static UUID orchiserapias_Uuid = UUID.fromString("0aee7eea-84e7-4b61-8cb6-d17313cc9b80"); |
|
39 |
|
|
40 |
static UUID epilobium_aschersonianum_Uuid = UUID.fromString("e13ea422-5d45-477b-ade3-8dc84dbc9dbc"); |
|
41 |
|
|
42 |
// |
|
43 |
static UUID aegilops_biuncialis_x_geniculata_Uuid = UUID.fromString("88ff0fbb-c0df-46c1-9969-cf318ea97dbb"); |
|
44 |
|
|
45 |
|
|
46 |
@Test |
|
47 |
public void orchiserapias() throws MalformedURLException { |
|
48 |
TaxonSynonymyPage p = new TaxonSynonymyPage(driver, getContext(), orchiserapias_Uuid); |
|
49 |
String expectedName = "×Orchiserapias"; |
|
50 |
assertEquals(getContext().prepareTitle(expectedName), driver.getTitle()); |
|
51 |
assertEquals(expectedName, p.getAcceptedNameText()); |
|
52 |
assertEquals("≡ Orchis × Serapias", p.getHomotypicalGroupSynonymName(1)); |
|
53 |
} |
|
54 |
|
|
55 |
@Test |
|
56 |
public void epilobium_aschersonianum() throws MalformedURLException { |
|
57 |
TaxonSynonymyPage p = new TaxonSynonymyPage(driver, getContext(), epilobium_aschersonianum_Uuid); |
|
58 |
assertEquals(getContext().prepareTitle("Epilobium ×aschersonianum"), driver.getTitle()); |
|
59 |
assertEquals("Epilobium ×aschersonianum Hausskn.", p.getAcceptedNameText()); |
|
60 |
assertEquals("≡ Epilobium lanceolatum × parviflorum", p.getHomotypicalGroupSynonymName(1)); |
|
61 |
} |
|
62 |
|
|
63 |
@Test |
|
64 |
public void aegilops_biuncialis_x_geniculata() throws MalformedURLException { |
|
65 |
TaxonProfilePage p = new TaxonProfilePage(driver, getContext(), aegilops_biuncialis_x_geniculata_Uuid); |
|
66 |
assertEquals(getContext().prepareTitle("Aegilops biuncialis × geniculata"), driver.getTitle()); |
|
67 |
ClassificationTreeBlock classificationTree = p.getClassificationTree(); |
|
68 |
ClassificationTreeElement focusedElement = classificationTree.getFocusedElement(); |
|
69 |
assertTrue(classificationTree.isVisibleInViewPort(focusedElement)); |
|
70 |
assertEquals("Abbreviated form of name should be used", "A. biuncialis × geniculata", focusedElement.getTaxonName()); |
|
71 |
} |
|
72 |
|
|
73 |
} |
Also available in: Unified diff
CRLF will be replaced by LF issues