Revision 4dbcb616
Added by Andreas Müller over 3 years ago
cdmlib-model/src/test/java/eu/etaxonomy/cdm/strategy/cache/reference/ReferenceTypeTest.java | ||
---|---|---|
1 | 1 |
/** |
2 |
* |
|
3 |
*/ |
|
2 |
* Copyright (C) 2009 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 |
*/ |
|
4 | 9 |
package eu.etaxonomy.cdm.strategy.cache.reference; |
5 | 10 |
|
6 |
|
|
7 | 11 |
import org.junit.Assert; |
8 |
import org.junit.Before; |
|
9 |
import org.junit.BeforeClass; |
|
10 | 12 |
import org.junit.Test; |
11 | 13 |
|
12 | 14 |
import eu.etaxonomy.cdm.model.reference.ReferenceType; |
13 | 15 |
|
14 | 16 |
/** |
15 | 17 |
* @author a.mueller |
16 |
* |
|
17 | 18 |
*/ |
18 | 19 |
public class ReferenceTypeTest { |
19 | 20 |
|
20 |
/** |
|
21 |
* @throws java.lang.Exception |
|
22 |
*/ |
|
23 |
@BeforeClass |
|
24 |
public static void setUpBeforeClass() throws Exception { |
|
25 |
} |
|
26 |
|
|
27 |
/** |
|
28 |
* @throws java.lang.Exception |
|
29 |
*/ |
|
30 |
@Before |
|
31 |
public void setUp() throws Exception { |
|
32 |
} |
|
33 |
|
|
34 | 21 |
// ****************************** TESTS *************************************** |
35 |
|
|
22 |
|
|
36 | 23 |
@Test |
37 | 24 |
public void testIsPrintedUnit(){ |
38 | 25 |
Assert.assertTrue("Proceedings must be printed unit", ReferenceType.Proceedings.isPrintedUnit()); |
... | ... | |
52 | 39 |
Assert.assertFalse("Thesis must not be printed unit", ReferenceType.Thesis.isPrintedUnit()); |
53 | 40 |
Assert.assertFalse("WebPage must not be printed unit", ReferenceType.WebPage.isPrintedUnit()); |
54 | 41 |
} |
55 |
|
|
42 |
|
|
56 | 43 |
@Test |
57 | 44 |
public void testIsPublication(){ |
58 | 45 |
Assert.assertTrue("Proceedings must be publication", ReferenceType.Proceedings.isPublication()); |
... | ... | |
72 | 59 |
Assert.assertTrue("Thesis must be publication", ReferenceType.Thesis.isPublication()); |
73 | 60 |
Assert.assertTrue("WebPage must be publication", ReferenceType.WebPage.isPublication()); |
74 | 61 |
} |
75 |
|
|
62 |
|
|
76 | 63 |
|
77 | 64 |
@Test |
78 | 65 |
public void testIsVolumeReference(){ |
... | ... | |
93 | 80 |
Assert.assertFalse("Thesis must not be volume reference", ReferenceType.Thesis.isVolumeReference()); |
94 | 81 |
Assert.assertFalse("WebPage must not be volume reference", ReferenceType.WebPage.isVolumeReference()); |
95 | 82 |
} |
96 |
|
|
83 |
|
|
97 | 84 |
|
98 | 85 |
@Test |
99 | 86 |
public void testIsSection(){ |
Also available in: Unified diff
cleanup and use TermTestBase for model tests