Skip to content
Snippets Groups Projects
Commit 4de904f1 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

test parameters are assigned via test framework

parent cefe0850
No related branches found
No related tags found
1 merge request!595Resolve "Small molecules annotators to be rearranged"
......@@ -12,6 +12,7 @@ import org.apache.log4j.Logger;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
import org.junit.runners.Parameterized.Parameter;
import org.junit.runners.Parameterized.Parameters;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;
......@@ -34,20 +35,17 @@ import lcsb.mapviewer.persist.DbUtils;
public class ElementAnnotatorImplementationsTest extends AnnotationTestFunctions {
@SuppressWarnings("unused")
private static Logger logger = Logger.getLogger(ElementAnnotatorImplementationsTest.class);
private Class<? extends ElementAnnotator> elementAnnotator;
private MiriamData sourceIdentifier;
private BioEntity bioEntity;
@Parameter
public Class<? extends ElementAnnotator> elementAnnotator;
@Parameter(1)
public MiriamData sourceIdentifier;
@Parameter(2)
public BioEntity bioEntity;
static ApplicationContext applicationContext;
public ElementAnnotatorImplementationsTest(Class<? extends ElementAnnotator> annotator, MiriamData sourceIdentifier,
BioEntity entity) {
this.elementAnnotator = annotator;
this.sourceIdentifier = sourceIdentifier;
this.bioEntity = entity;
}
@Parameters(name = "{index} : {0}")
@Parameters(name = "{0}")
public static Collection<Object[]> data() throws IOException {
List<Object[]> result = new ArrayList<>();
applicationContext = new AnnotationConfigApplicationContext(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment