Commit 4c137b82 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

test case simplified

parent f90c47c2
...@@ -7,18 +7,13 @@ import static org.junit.Assert.assertTrue; ...@@ -7,18 +7,13 @@ import static org.junit.Assert.assertTrue;
import java.io.FileNotFoundException; import java.io.FileNotFoundException;
import java.util.HashSet; import java.util.HashSet;
import java.util.List;
import java.util.Set; import java.util.Set;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.apache.log4j.spi.LoggingEvent;
import org.junit.After;
import org.junit.Before;
import org.junit.Test; import org.junit.Test;
import lcsb.mapviewer.commands.CreateHierarchyCommand; import lcsb.mapviewer.commands.CreateHierarchyCommand;
import lcsb.mapviewer.common.Configuration; import lcsb.mapviewer.common.Configuration;
import lcsb.mapviewer.common.EventStorageLoggerAppender;
import lcsb.mapviewer.converter.ConverterParams; import lcsb.mapviewer.converter.ConverterParams;
import lcsb.mapviewer.converter.InvalidInputDataExecption; import lcsb.mapviewer.converter.InvalidInputDataExecption;
import lcsb.mapviewer.model.map.compartment.Compartment; import lcsb.mapviewer.model.map.compartment.Compartment;
...@@ -31,28 +26,10 @@ import lcsb.mapviewer.model.map.species.Gene; ...@@ -31,28 +26,10 @@ import lcsb.mapviewer.model.map.species.Gene;
import lcsb.mapviewer.model.map.species.GenericProtein; import lcsb.mapviewer.model.map.species.GenericProtein;
import lcsb.mapviewer.model.map.species.Species; import lcsb.mapviewer.model.map.species.Species;
public class SbmlParserTest { public class SbmlParserTest extends SbmlTestFunctions {
Logger logger = Logger.getLogger(SbmlParserTest.class); Logger logger = Logger.getLogger(SbmlParserTest.class);
SbmlParser parser = new SbmlParser(); SbmlParser parser = new SbmlParser();
private EventStorageLoggerAppender appender;
@Before
public final void _setUp() throws Exception {
Logger.getRootLogger().removeAppender(appender);
appender = new EventStorageLoggerAppender();
Logger.getRootLogger().addAppender(appender);
}
@After
public final void _tearDown() throws Exception {
Logger.getRootLogger().removeAppender(appender);
}
protected List<LoggingEvent> getWarnings() {
return appender.getWarnings();
}
@Test @Test
public void testParseCompartment() throws FileNotFoundException, InvalidInputDataExecption { public void testParseCompartment() throws FileNotFoundException, InvalidInputDataExecption {
Model model = parser.createModel( Model model = parser.createModel(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment