Project

General

Profile

Download (1.87 KB) Statistics
| Branch: | Tag: | Revision:
1
/**
2
* Copyright (C) 2007 EDIT
3
* European Distributed Institute of Taxonomy 
4
* http://www.e-taxonomy.eu
5
* 
6
* The contents of this file are subject to the Mozilla Public License Version 1.1
7
* See LICENSE.TXT at the top of this package for the full license terms.
8
*/
9

    
10
package eu.etaxonomy.cdm.model.name;
11

    
12
import static org.junit.Assert.assertEquals;
13
import java.util.UUID;
14

    
15
import org.apache.log4j.Logger;
16
import org.junit.BeforeClass;
17
import org.junit.Test;
18

    
19
import eu.etaxonomy.cdm.model.common.DefaultTermInitializer;
20
import eu.etaxonomy.cdm.test.unit.EntityTestBase;
21

    
22
/**
23
 * @author a.babadshanjan
24
 * @since 25.03.2009
25
 */
26
public class NomenclaturalStatusTypeTest extends EntityTestBase {
27
	@SuppressWarnings("unused")
28
	private static final Logger logger = Logger.getLogger(NomenclaturalStatusTypeTest.class);
29

    
30
	private static final UUID uuidDoubtful = UUID.fromString("0ffeb39e-872e-4c0f-85ba-a4150d9f9e7d");
31
	private static final UUID uuidCombNov = UUID.fromString("ed508710-deef-44b1-96f6-1ce6d2c9c884");
32
	private static final UUID uuidNotAvailable = UUID.fromString("6d9ed462-b761-4da3-9304-4749e883d4eb");
33
	
34

    
35
	@BeforeClass
36
	public static void setUp() {
37
		DefaultTermInitializer vocabularyStore = new DefaultTermInitializer();
38
		vocabularyStore.initialize();
39
	}
40
	
41
	@Test
42
	public void testNomenclaturalStatusTypeStringString() {
43
		NomenclaturalStatusType term = NomenclaturalStatusType.NewInstance("term", "label", null);
44
		assertEquals("label", term.getLabel());
45
	}
46
	
47
	@Test
48
	public void testDoubtful() {
49
		assertEquals(uuidDoubtful,  NomenclaturalStatusType.DOUBTFUL().getUuid());	
50
	}
51
	
52
	
53
	@Test
54
	public void testCombNov() {
55
		assertEquals(uuidCombNov,  NomenclaturalStatusType.COMB_NOV().getUuid());	
56
	}
57
	
58
	@Test
59
	public void testNotAvailable() {
60
		assertEquals(uuidNotAvailable,  NomenclaturalStatusType.ZOO_NOT_AVAILABLE().getUuid());	
61
	}
62
}
(7-7/15)