1   package de.fu_berlin.ties.extract;
2   
3   import junit.framework.TestCase;
4   // JUnitDoclet begin import
5   import de.fu_berlin.ties.classify.Probability;
6   import de.fu_berlin.ties.extract.Extraction;
7   import de.fu_berlin.ties.text.TokenDetails;
8   // JUnitDoclet end import
9   
10  /***
11  * Generated by JUnitDoclet, a tool provided by
12  * ObjectFab GmbH under LGPL.
13  * Please see www.junitdoclet.org, www.gnu.org
14  * and www.objectfab.de for informations about
15  * the tool, the licence and the authors.
16  */
17  
18  
19  public class ExtractionTest
20  // JUnitDoclet begin extends_implements
21  extends TestCase
22  // JUnitDoclet end extends_implements
23  {
24    // JUnitDoclet begin class
25    Extraction extraction = null;
26    // JUnitDoclet end class
27    
28    public ExtractionTest(String name) {
29      // JUnitDoclet begin method ExtractionTest
30      super(name);
31      // JUnitDoclet end method ExtractionTest
32    }
33    
34    public de.fu_berlin.ties.extract.Extraction createInstance() throws Exception {
35      // JUnitDoclet begin method testcase.createInstance
36      final TokenDetails details =
37          new TokenDetails("Dr. Weizenbaum", 2, 547, true);
38      final Probability prob = new Probability(0.89, 0.683);
39      return new Extraction("speaker", details, prob); 
40      // JUnitDoclet end method testcase.createInstance
41    }
42    
43    protected void setUp() throws Exception {
44      // JUnitDoclet begin method testcase.setUp
45      super.setUp();
46      extraction = createInstance();
47      // JUnitDoclet end method testcase.setUp
48    }
49    
50    protected void tearDown() throws Exception {
51      // JUnitDoclet begin method testcase.tearDown
52      extraction = null;
53      super.tearDown();
54      // JUnitDoclet end method testcase.tearDown
55    }
56    
57    public void testAddToken() throws Exception {
58      // JUnitDoclet begin method addToken
59      // JUnitDoclet end method addToken
60    }
61    
62    public void testEquals() throws Exception {
63      // JUnitDoclet begin method equals
64      // JUnitDoclet end method equals
65    }
66    
67    public void testGetFirstTokenRep() throws Exception {
68      // JUnitDoclet begin method getFirstTokenRep
69      // JUnitDoclet end method getFirstTokenRep
70    }
71    
72    public void testGetIndex() throws Exception {
73      // JUnitDoclet begin method getIndex
74      // JUnitDoclet end method getIndex
75    }
76    
77    public void testGetText() throws Exception {
78      // JUnitDoclet begin method getText
79      // JUnitDoclet end method getText
80    }
81    
82    public void testGetVisibleChars() throws Exception {
83      // JUnitDoclet begin method getVisibleChars
84      // JUnitDoclet end method getVisibleChars
85    }
86    
87    public void testHashCode() throws Exception {
88      // JUnitDoclet begin method hashCode
89      // JUnitDoclet end method hashCode
90    }
91    
92    public void testRemoveToken() throws Exception {
93      // JUnitDoclet begin method removeToken
94      // JUnitDoclet end method removeToken
95    }
96    
97    public void testSetIsFirstTokenRepIgnored() throws Exception {
98      // JUnitDoclet begin method setFirstTokenRepIgnored isFirstTokenRepIgnored
99      boolean[] tests = {true, false};
100     
101     for (int i = 0; i < tests.length; i++) {
102       extraction.setFirstTokenRepIgnored(tests[i]);
103       assertEquals(tests[i], extraction.isFirstTokenRepIgnored());
104     }
105     // JUnitDoclet end method setFirstTokenRepIgnored isFirstTokenRepIgnored
106   }
107   
108   public void testSetIsSealed() throws Exception {
109     // JUnitDoclet begin method setSealed isSealed
110     boolean[] tests = {true, false};
111     
112     for (int i = 0; i < tests.length; i++) {
113       extraction.setSealed(tests[i]);
114       assertEquals(tests[i], extraction.isSealed());
115     }
116     // JUnitDoclet end method setSealed isSealed
117   }
118   
119   public void testStoreFields() throws Exception {
120     // JUnitDoclet begin method storeFields
121     // JUnitDoclet end method storeFields
122   }
123   
124   public void testTokenCount() throws Exception {
125     // JUnitDoclet begin method tokenCount
126     // JUnitDoclet end method tokenCount
127   }
128   
129   
130   
131   /***
132   * JUnitDoclet moves marker to this method, if there is not match
133   * for them in the regenerated code and if the marker is not empty.
134   * This way, no test gets lost when regenerating after renaming.
135   * Method testVault is supposed to be empty.
136   */
137   public void testVault() throws Exception {
138     // JUnitDoclet begin method testcase.testVault
139     // JUnitDoclet end method testcase.testVault
140   }
141   
142   public static void main(String[] args) {
143     // JUnitDoclet begin method testcase.main
144     junit.textui.TestRunner.run(ExtractionTest.class);
145     // JUnitDoclet end method testcase.main
146   }
147 }