Project

General

Profile

« Previous | Next » 

Revision 6e42c2eb

Added by Andreas Müller over 2 years ago

fix selenium tests for updated caches (cont.)

View differences:

src/test/java/eu/etaxonomy/dataportal/selenium/tests/cyprus/Allium_guttatum_subsp_guttatum_TaxonProfileTest.java
123 123
        assertEquals("rgba(255, 255, 0, 1)", footNoteKey_1.getElement().getCssValue("background-color"));
124 124
        assertEquals("rgba(255, 255, 0, 1)", footNote_1.getElement().getCssValue("background-color"));
125 125

  
126
        assertEquals("A. R. D. Meikle, Flora of Cyprus 2. 1985", footNote_1.getText());
126
        assertEquals("A. Hand, R. 2009: Supplementary notes to the flora of Cyprus VI. – Willdenowia 39: 301-325", footNote_1.getText());
127 127

  
128 128
        WebElement distributionMapImage = featureBlock.getElement().findElement(By.className("distribution_map"));
129 129
//		assertEquals("http://edit.br.fgov.be/edit_wp5/v1.1/rest_gen.php?title=a:indigenous&ad=cyprusdivs:bdcode:a:2&as=z:ffffff,606060,,|y:1874CD,,|a:339966,,0.1,&l=background_gis:y,cyprusdivs:z&ms=500,380&bbox=32,34,35,36&label=1&img=true&legend=1&mlp=3&mc_s=Georgia,15,blue&mc=&recalculate=false", distributionMapImage.getAttribute("src"));
src/test/java/eu/etaxonomy/dataportal/selenium/tests/palmae/Calamus_acanthospathus_TaxonProfileTest.java
43 43
     * string generation in the drupal code which need to be removed
44 44
     * in order to retain the maintainability of the code.
45 45
     */
46
    String evans_et_al_referenceCitation = "T. Evans & K. Sengdala & B. Thammavong & O.V. Viengkham & J. Dransfield, A Synopsis of the Rattans (Arecaceae: Calamoideae) of Laos and Neighbouring Parts of Indochina. 2002";
46
    String evans_et_al_referenceCitation = "Evans, T., Sengdala, K., Thammavong, B., Viengkham, O.V. & Dransfield, J. 2002: A Synopsis of the Rattans (Arecaceae: Calamoideae) of Laos and Neighbouring Parts of Indochina";
47 47

  
48 48
    @Before
49 49
    public void setUp() throws MalformedURLException {
src/test/java/eu/etaxonomy/dataportal/selenium/tests/palmae/Iriartea_deltoidea_UsesTest.java
129 129
        /* Biology And Ecology */
130 130
        String featureClass = "uses";
131 131
        String featureLabel = "Uses";
132
        String blockTextFull = featureLabel + "\nThe outer part of the stems are used throughout its range for building purposes, e.g., floors, posts, poles; also for blowguns, bows, harpoons and arrow points; and also for firewood. The leaves are used for thatching and basketry. The heart and seeds are occasionally eaten. The inside layer of the leaf sheath is used to give women strength in labor (Shemluck & Ness 163, Ecuador). Hollowed-out stems are used as coffins by Embera Indians in Colombia (R. Bernal, pers. comm.). Steven King (pers. comm.) reports that in northern Peru Angotere-Secoya and Quechua people use the stems of I. deltoidea as canoes. Large specimens are selected and carefully felled. The soft central ground tissue is removed from the center of the stem, and base and apex fashioned into bow and stern. The canoes are widely used for shortening trips, especially long overland trips where short-cuts can be made by river. Canoes last about two or three months. Such is the demand for these temporary canoes that many of the larger specimens of Iriartea have been felled in this area. Rodrigo Bernal (pers. comm.) reports that in Colombia the Embera Indians of the Choco tie the stems together and use them as rafts. Since these are so heavy they are only used for downstream travel. (Henderson, A. 1990. Introduction and the Iriarteinae. Flora Neotropica Monograph 53.)";
132
        String blockTextFull = featureLabel + "\nThe outer part of the stems are used throughout its range for building purposes, e.g., floors, posts, poles; also for blowguns, bows, harpoons and arrow points; and also for firewood. The leaves are used for thatching and basketry. The heart and seeds are occasionally eaten. The inside layer of the leaf sheath is used to give women strength in labor (Shemluck & Ness 163, Ecuador). Hollowed-out stems are used as coffins by Embera Indians in Colombia (R. Bernal, pers. comm.). Steven King (pers. comm.) reports that in northern Peru Angotere-Secoya and Quechua people use the stems of I. deltoidea as canoes. Large specimens are selected and carefully felled. The soft central ground tissue is removed from the center of the stem, and base and apex fashioned into bow and stern. The canoes are widely used for shortening trips, especially long overland trips where short-cuts can be made by river. Canoes last about two or three months. Such is the demand for these temporary canoes that many of the larger specimens of Iriartea have been felled in this area. Rodrigo Bernal (pers. comm.) reports that in Colombia the Embera Indians of the Choco tie the stems together and use them as rafts. Since these are so heavy they are only used for downstream travel. (Henderson, A. 1990: Introduction and the Iriarteinae. – Flora Neotropica Monographs 53)";
133 133
        expectedCssDisplay = "list-item";
134 134
        expectedListStyleType = "none";
135 135

  
......
165 165
                + "Construction Houses Stem Indigenous Tsimane/Mosetene Bolivia";
166 166

  
167 167

  
168
        assertEquals("Iriartea deltoidea Ruiz & Pav.: Alimentación humana. Palmito. Cuando es tierno, se corta y pela para consumir crudo en ensalada. Comercial. Semilla. Es utilizada en la elaboración de collares. Construcción. Estípite. Construcción de viviendas, en postes y vigas transversales. La parte externa es cortada el segmentos longitudinales, secada, y empleada en las paredes, suelo, y como cuerda natural. Construcción. Hoja. Techado de campamentos temporales. Utensilios y herr. de uso doméstico. Estípite. Elaboración de \"guarachas\" (estantes para depositar objetos). Utensilios y herr. de uso doméstico. Hoja (vaina). La vaina seca de la hoja se utiliza para hacer recipientes. (Armesilla, P.J., Usos de las palmeras (Arecaceae),en la Reserva de la Biosfera-Tierra Comunitaria de Orígen Pilón Lajas, (Bolivia). 2006)\n"
168
        assertEquals("Iriartea deltoidea Ruiz & Pav.: Alimentación humana. Palmito. Cuando es tierno, se corta y pela para consumir crudo en ensalada. Comercial. Semilla. Es utilizada en la elaboración de collares. Construcción. Estípite. Construcción de viviendas, en postes y vigas transversales. La parte externa es cortada el segmentos longitudinales, secada, y empleada en las paredes, suelo, y como cuerda natural. Construcción. Hoja. Techado de campamentos temporales. Utensilios y herr. de uso doméstico. Estípite. Elaboración de \"guarachas\" (estantes para depositar objetos). Utensilios y herr. de uso doméstico. Hoja (vaina). La vaina seca de la hoja se utiliza para hacer recipientes. (Armesilla, P.J. 2006: Usos de las palmeras (Arecaceae),en la Reserva de la Biosfera-Tierra Comunitaria de Orígen Pilón Lajas, (Bolivia))\n"
169 169
                + item14UseRecordText,
170 170
                listItems.get(0).getText());
171 171
        // tabular
src/test/java/eu/etaxonomy/dataportal/selenium/tests/reference/DescriptionElementsTest.java
1
/**
1
Lem[,] New Species in the/**
2 2
 * Copyright (C) 2009 EDIT
3 3
 * European Distributed Institute of Taxonomy
4 4
 * http://www.e-taxonomy.eu
......
53 53
        FeatureBlock fb = p.getFeatureBlockAt(0, "biology-and-ecology", "div", "span");
54 54
        assertNotNull(fb);
55 55
        assertEquals(3, fb.getFeatureBlockElements().size());
56
        assertEquals("Flowers with white blossoms on Testisland A. 0000-05 to 0000-06 (Lem, New Species in the solar system: p.99)", fb.getFeatureBlockElements().get(0).getText());
57
        assertEquals("Flowers with white blossoms on Testisland B. Mai to June (Lem, New Species in the solar system: p.99)", fb.getFeatureBlockElements().get(1).getText());
56
        assertEquals("Flowers with white blossoms on Testisland A. 0000-05 to 0000-06 (Lem: New Species in the solar system: p.99)", fb.getFeatureBlockElements().get(0).getText());
57
        assertEquals("Flowers with white blossoms on Testisland B. Mai to June (Lem: New Species in the solar system: p.99)", fb.getFeatureBlockElements().get(1).getText());
58 58
        assertEquals("Flowers with white blossoms on Testisland C. 2000 to 2000-05", fb.getFeatureBlockElements().get(2).getText());
59 59

  
60 60
    }
src/test/java/eu/etaxonomy/dataportal/selenium/tests/reference/FootnoteTest.java
75 75
        assertEquals(5, footnotes.size());
76 76
        assertEquals("1. Editorial note on Nodosilinea radiophila", footnotes.get(0).getText());
77 77
        assertEquals("2. editorial note on the fieldunit", footnotes.get(1).getText());
78
        assertEquals("3. Art. 77.7; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 22",
78
        assertEquals("3. Art. 77.7; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 22",
79 79
                footnotes.get(2).getText());
80
        assertEquals("4. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
80
        assertEquals("4. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
81 81
                footnotes.get(3).getText());
82 82
        assertEquals("5. Editorial annotation on Nodosilinea sensensia (Blanco) Heidari & Hauer ex Lem",
83 83
                footnotes.get(4).getText());
......
107 107
        assertEquals(6, footnotes.size());
108 108
        assertEquals("1. Editorial note on Nodosilinea radiophila",
109 109
                footnotes.get(0).getText());
110
        assertEquals("2. Art. 77.7; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 22",
110
        assertEquals("2. Art. 77.7; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 22",
111 111
                footnotes.get(1).getText());
112
        assertEquals("3. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
112
        assertEquals("3. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
113 113
                footnotes.get(2).getText());
114 114
        assertEquals("4. Editorial annotation on Nodosilinea sensensia (Blanco) Heidari & Hauer ex Lem",
115 115
                        footnotes.get(3).getText());
src/test/java/eu/etaxonomy/dataportal/selenium/tests/reference/MisappliedNamesTest.java
96 96
        List<BaseElement> footnotes = ElementUtils.findFootNotes(p.getTaxonRelationships());
97 97
        assertEquals(2, footnotes.size());
98 98
        assertEquals("1. A&S: Plantas vasculares de Oz", footnotes.get(0).getText());
99
        assertEquals("2. Lem, New Species in the solar system", footnotes.get(1).getText());
99
        assertEquals("2. Lem: New Species in the solar system", footnotes.get(1).getText());
100 100
        // "Species solaris" must not be in the footnotes as it has the same title as the short citation
101 101

  
102 102
    }
......
116 116
        List<BaseElement> footnotes = ElementUtils.findFootNotes(p.getTaxonRelationships());
117 117
        assertEquals(2, footnotes.size());
118 118
        assertEquals("1. A&S: Plantas vasculares de Oz", footnotes.get(0).getText());
119
        assertEquals("2. Lem, New Species in the solar system", footnotes.get(1).getText());
119
        assertEquals("2. Lem: New Species in the solar system", footnotes.get(1).getText());
120 120
    }
121 121

  
122 122
    /**
......
156 156

  
157 157
        List<BaseElement> footnotes = ElementUtils.findFootNotes(p.getTaxonRelationships());
158 158
        assertEquals(1, footnotes.size());
159
        assertEquals("1. Greuter, W. & Rankin Rodríguez, R, Plantas vasculares de Cuba: inventario preliminar. Tercera edición, actualizada. Vascular plants of Cuba: a preliminary checklist. Third updated edition.", footnotes.get(0).getText());
159
        assertEquals("1. Greuter, W. & Rankin Rodríguez, R: Plantas vasculares de Cuba: inventario preliminar. Tercera edición, actualizada. Vascular plants of Cuba: a preliminary checklist. Third updated edition.", footnotes.get(0).getText());
160 160
    }
161 161

  
162 162
    /**
src/test/java/eu/etaxonomy/dataportal/selenium/tests/reference/NameRelationshipsTest.java
78 78
        List<BaseElement> footnotes = regItem.getRegistrationFootnotes();
79 79
        assertEquals(9, footnotes.size());
80 80
        assertEquals(
81
                "1. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
81
                "1. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
82 82
                footnotes .get(0).getText());
83 83
        assertEquals(
84 84
                "2. Editorial annotation on Nodosilinea sensensia (Blanco) Heidari & Hauer ex Lem",
85 85
                footnotes .get(1).getText());
86 86
        assertEquals(
87
                "3. Art. 77.7; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 22",
87
                "3. Art. 77.7; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 22",
88 88
                footnotes .get(2).getText());
89 89
        assertEquals(
90 90
                "4. Editorial note on Nodosilinea radiophila",
......
99 99
                "7. Editorial annotation on Nodosilinea sensensia, Species solaris",
100 100
                footnotes .get(6).getText());
101 101
        assertEquals(
102
                "8. Art. 88.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 33",
102
                "8. Art. 88.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 33",
103 103
                footnotes .get(7).getText());
104 104
        assertEquals(
105 105
                "9. Editorial annotation on Nodosilinea sensensi",
......
119 119
        List<BaseElement> footnotes = p.getHomotypicalGroupFootNotes();
120 120
        assertEquals(7, footnotes.size());
121 121
        assertEquals(
122
                "1. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
122
                "1. Art. 99.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 11",
123 123
                footnotes .get(0).getText());
124 124
        assertEquals(
125 125
                "2. Editorial annotation on Nodosilinea sensensia (Blanco) Heidari & Hauer ex Lem",
......
134 134
                "5. Editorial annotation on Nodosilinea blockensis, New Species in the solar system",
135 135
                footnotes.get(4).getText());
136 136
        assertEquals(
137
                "6. Art. 88.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al., International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 33",
137
                "6. Art. 88.9; Turland, N.J., Wiersema, J.H., Barrie, F.R. & al.: International Code of Nomenclature for algae, fungi, and plants (Shenzhen Code) adopted by the Nineteenth International Botanical Congress Shenzhen, China, July 2017: 33",
138 138
                footnotes.get(5).getText());
139 139
        assertEquals(
140 140
                "7. Editorial annotation on Nodosilinea sensensi",

Also available in: Unified diff