Project

General

Profile

« Previous | Next » 

Revision b2a2e465

Added by Andreas Müller almost 8 years ago

Add secundum micro reference to cache strategy #5767

View differences:

cdmlib-model/src/test/java/eu/etaxonomy/cdm/strategy/cache/taxon/TaxonBaseDefaultCacheStrategyTest.java
139 139
		assertEquals("Cichorium glandulosum Boiss. \u0026 A. Huet sec. Sp.Pl.", taxon.getTitleCache());
140 140
	}
141 141

  
142
	@SuppressWarnings("deprecation")
143 142
    @Test
144 143
	public void testProtectedTitleCache(){
145 144
	    TaxonBase<?> taxonBase = Taxon.NewInstance(name, sec);
146
        taxonBase.setProtectedTitleCache(true);
147
        taxonBase.setTitleCache("abc");
145
        taxonBase.setTitleCache("abc", true);
148 146
        taxonBase.setDoubtful(true);
149 147
        Assert.assertEquals("abc", taxonBase.getTitleCache());
150 148
	}
149

  
150
    @Test
151
    public void testMicroReference(){
152
        TaxonBase<?> taxonBase = Taxon.NewInstance(name, sec);
153
        String secMicroRef = "p. 553";
154
        taxonBase.setSecMicroReference(secMicroRef);
155
        assertEquals("Taxon titlecache is wrong", expectedNameTitleCache + " sec. Sp.Pl.: " + secMicroRef,
156
                taxonBase.getTitleCache());
157

  
158

  
159
    }
151 160
}

Also available in: Unified diff