Project

General

Profile

« Previous | Next » 

Revision 9013

remove annotator service test -- this feature has been moved upstream

View differences:

test/edu/ucsb/nceas/metacat/annotation/AnnotatorServiceTest.java
1
/**  '$RCSfile$'
2
 *  Copyright: 2010 Regents of the University of California and the
3
 *              National Center for Ecological Analysis and Synthesis
4
 *
5
 * This program is free software; you can redistribute it and/or modify
6
 * it under the terms of the GNU General Public License as published by
7
 * the Free Software Foundation; either version 2 of the License, or
8
 * (at your option) any later version.
9
 *
10
 * This program is distributed in the hope that it will be useful,
11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13
 * GNU General Public License for more details.
14
 *
15
 * You should have received a copy of the GNU General Public License
16
 * along with this program; if not, write to the Free Software
17
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
18
 */
19
package edu.ucsb.nceas.metacat.annotation;
20

  
21
import java.util.List;
22
import java.util.Map;
23

  
24
import junit.framework.Test;
25
import junit.framework.TestSuite;
26
import edu.ucsb.nceas.MCTestCase;
27

  
28
public class AnnotatorServiceTest extends MCTestCase {
29

  
30
	
31
	/**
32
	 * constructor for the test
33
	 */
34
	public AnnotatorServiceTest(String name) {
35
		super(name);
36
	}
37

  
38
	/**
39
	 * Establish a testing framework by initializing appropriate objects
40
	 */
41
	public void setUp() throws Exception {
42
		super.setUp();
43
	}
44

  
45
	/**
46
	 * Release any objects after tests are complete
47
	 */
48
	public void tearDown() {
49
	}
50

  
51
	/**
52
	 * Create a suite of tests to be run together
53
	 */
54
	public static Test suite() {
55
		TestSuite suite = new TestSuite();
56
		suite.addTest(new AnnotatorServiceTest("testLookup"));
57

  
58
		return suite;
59
	}
60
	
61
	public void testLookup() {
62
		String pid = "test.2014090915254865302.1";
63
		Map<String, List<Object>> fields = AnnotatorService.lookUpAnnotations(pid);
64
		assertTrue(fields.containsKey("characteristic_sm"));
65
	}
66
	
67

  
68
}
69 0

  

Also available in: Unified diff