<commit_before>package org.cleartk.clearnlp;


import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

import junit.framework.Assert;


import org.apache.uima.analysis_engine.AnalysisEngine;
import org.cleartk.test.CleartkTestBase;
import org.cleartk.token.type.Sentence;
import org.cleartk.token.type.Token;
import org.junit.Test;
import org.uimafit.factory.AnalysisEngineFactory;
import org.uimafit.testing.factory.TokenBuilder;
import org.uimafit.util.JCasUtil;

public class PosTaggerTest extends CleartkTestBase {
	protected TokenBuilder<Token, Sentence> tokenBuilder;
	protected static AnalysisEngine posTagger;

	static {
		try {
			posTagger = AnalysisEngineFactory.createPrimitive(Tokenizer.getDescription());
		} catch (Exception e) {
			e.printStackTrace();
		}
	}	


	@Test
	public void posTaggerTest() throws Exception {
		this.jCas.reset();
		AnalysisEngine engine = AnalysisEngineFactory.createPrimitive(PosTaggerAndMPAnalyzer.getDescription());
		this.tokenBuilder.buildTokens(
				this.jCas,
				"The brown fox jumped quickly over the lazy dog.",
				"The brown fox jumped quickly over the lazy dog .");
		engine.process(this.jCas);

		List<String> expected = Arrays.asList("DT JJ NN VBD RB IN DT JJ NN .".split(" "));
		List<String> actual = new ArrayList<String>();
		for (Token token : JCasUtil.select(this.jCas, Token.class)) {
			actual.add(token.getPos());
		}
		System.out.println(actual);
		System.out.println(expected);
		Assert.assertEquals(expected, actual);
	}
}<commit_msg>Removed print statements from PosTaggerTest	<commit_after>package org.cleartk.clearnlp;


import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

import junit.framework.Assert;


import org.apache.uima.analysis_engine.AnalysisEngine;
import org.cleartk.test.CleartkTestBase;
import org.cleartk.token.type.Sentence;
import org.cleartk.token.type.Token;
import org.junit.Test;
import org.uimafit.factory.AnalysisEngineFactory;
import org.uimafit.testing.factory.TokenBuilder;
import org.uimafit.util.JCasUtil;

public class PosTaggerTest extends CleartkTestBase {
	protected TokenBuilder<Token, Sentence> tokenBuilder;
	protected static AnalysisEngine posTagger;

	static {
		try {
			posTagger = AnalysisEngineFactory.createPrimitive(Tokenizer.getDescription());
		} catch (Exception e) {
			e.printStackTrace();
		}
	}	


	@Test
	public void posTaggerTest() throws Exception {
		this.jCas.reset();
		AnalysisEngine engine = AnalysisEngineFactory.createPrimitive(PosTaggerAndMPAnalyzer.getDescription());
		this.tokenBuilder.buildTokens(
				this.jCas,
				"The brown fox jumped quickly over the lazy dog.",
				"The brown fox jumped quickly over the lazy dog .");
		engine.process(this.jCas);

		List<String> expected = Arrays.asList("DT JJ NN VBD RB IN DT JJ NN .".split(" "));
		List<String> actual = new ArrayList<String>();
		for (Token token : JCasUtil.select(this.jCas, Token.class)) {
			actual.add(token.getPos());
		}
		Assert.assertEquals(expected, actual);
	}
}
{'fraction_non_alphanumeric': 0.11136890951276102, 'fraction_numerical': 0.0, 'mean_word_length': 5.01195219123506, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6721632', 'n_tokens_mistral': 1042, 'n_tokens_neox': 950, 'n_words': 211}