package semanticMarkup.ling.learn;

import java.util.ArrayList;
//import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;

import semanticMarkup.core.Treatment;


import org.junit.Test;


public class UnsupervisedClauseMarkupTest {
	
	@Test
	public void testUnsupervisedClauseMarkup() {
		String str = "Users/nescent/Phenoscape/TEST2/target/descriptions";
		UnsupervisedClauseMarkup t = new UnsupervisedClauseMarkup(str,"biocreative2012","plain","test");
		t.populatesents();
		
		List<Treatment> l_test = new ArrayList<Treatment>();
		//Map<String, String> m_test = new HashMap<String,String>();
		
		
		t.learn(l_test);
		t.getSentences();
		t.getSentencesForOrganStateMarker();
		t.getAdjNouns();
		t.getAdjNounSent();
		t.getSentenceTags();
		t.getBracketTags();
		t.getWordRoleTags();
		t.getWordToSources();
		t.getRoleToWords();
		t.getWordsToRoles();
		t.getHeuristicNouns();

		t.getTermCategories();


	}
}

@@ -29,16 +29,85 @@
 learn;%0A%0A
+import org.junit.Test;%0Aimport static org.junit.Assert.assertEquals;%0A%0A
 import j
@@ -264,33 +264,66 @@
 nt;%0A
-%0A%0A
 import 
-org.junit.Test;%0A
+semanticMarkup.ling.learn.UnsupervisedClauseMarkup;
 %0A%0Apu
@@ -488,16 +488,82 @@
 tions%22;%0A
+%09%09List%3CTreatment%3E treatments_l = new ArrayList%3CTreatment%3E();%0A%09%09%09%09%0A
 %09%09Unsupe
@@ -582,16 +582,21 @@
 Markup t
+ester
  = new U
@@ -664,176 +664,328 @@
 ;%0A%09%09
-t.populatesent
+assertEquals(%22Result%22, null, tester.getAdjNoun
 s()
+)
 ;%0A%09%09
-%0A%09%09List%3CTreatment%3E l_test = new ArrayList%3CTreatm
+assertEquals(%22Result%22, null, tester.getAdjNounS
 ent
-%3E
 ()
+)
 ;%0A%09%09
-//Map%3CString, String%3E m_test = new HashMap%3CString,String%3E();%0A%09%09%0A%09%09%0A%09%09t.learn(l_test);%0A%09%09t
+assertEquals(%22Result%22, null, tester.getBracketTags());%0A%09%09assertEquals(%22Result%22, null, tester.getHeuristicNouns());%0A%09%09assertEquals(%22Result%22, null, tester.getRoleToWords());%0A%09%09assertEquals(%22Result%22, null, tester
 .get
@@ -991,29 +991,64 @@
 tSentences()
+)
 ;%0A%09%09
-t
+assertEquals(%22Result%22, null, tester
 .getSentence
@@ -1073,54 +1073,48 @@
 er()
+)
 ;%0A%09%09
-t.getAdjNouns();%0A%09%09t.getAdjNounSent();%0A%09%09t
+assertEquals(%22Result%22, null, tester
 .get
@@ -1131,35 +1131,108 @@
 gs()
+)
 ;%0A%09%09
-t.getBracketTag
+assertEquals(%22Result%22, null, tester.getTermCategorie
 s()
+)
 ;%0A%09%09
-t
+assertEquals(%22Result%22, null, tester
 .get
@@ -1249,59 +1249,48 @@
 gs()
+)
 ;%0A%09%09
-t.getWordToSources();%0A%09%09t.getRoleToWords();%0A%09%09t
+assertEquals(%22Result%22, null, tester
 .get
@@ -1307,62 +1307,76 @@
 es()
+)
 ;%0A%09%09
-t.getHeuristicNouns();%0A%0A%09%09t.getTermCategori
+assertEquals(%22Result%22, null, tester.getWordToSourc
 es()
+)
 ;%0A%0A
+%09%09%0A%09%09
 %0A%09%7D%0A

Add JUnit test