blob: d4e6fc6a33266f0797ff29495dbeccd7391d4aab [file] [log] [blame]
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.uima.fit.util;
import java.io.File;
import java.io.IOException;
import org.apache.uima.UIMAException;
import org.apache.uima.analysis_engine.AnalysisEngineDescription;
import org.apache.uima.fit.ComponentTestBase;
import org.apache.uima.fit.factory.AnalysisEngineFactory;
import org.apache.uima.fit.factory.testAes.Annotator1;
import org.apache.uima.fit.factory.testAes.Annotator2;
import org.apache.uima.fit.factory.testAes.Annotator3;
import org.apache.uima.fit.pipeline.SimplePipeline;
import org.junit.Test;
public class SimplePipelineTest extends ComponentTestBase {
@Test
public void test1() throws UIMAException, IOException {
CasIOUtil.readJCas(jCas, new File("src/test/resources/data/docs/test.xmi"));
AnalysisEngineDescription aed1 = AnalysisEngineFactory.createEngineDescription(
Annotator1.class, typeSystemDescription);
AnalysisEngineDescription aed2 = AnalysisEngineFactory.createEngineDescription(
Annotator2.class, typeSystemDescription);
AnalysisEngineDescription aed3 = AnalysisEngineFactory.createEngineDescription(
Annotator3.class, typeSystemDescription);
SimplePipeline.runPipeline(jCas, aed1, aed2, aed3);
}
}