Commit aa22a2ac authored by Piotr Gawron's avatar Piotr Gawron
Browse files

remove unused variables

parent bef668b3
......@@ -3,8 +3,6 @@ package lcsb.mapviewer.cdplugin.copypaste;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotEquals;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Test;
import org.mockito.Mockito;
......@@ -13,7 +11,6 @@ import lcsb.mapviewer.cdplugin.CdPluginFunctions;
import lcsb.mapviewer.common.SystemClipboard;
public class CopyActionTest extends CdPluginFunctions {
private static Logger logger = LogManager.getLogger();
private SystemClipboard cp = new SystemClipboard();
......
......@@ -6,8 +6,6 @@ import static org.junit.Assert.assertNull;
import java.util.Set;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -19,7 +17,6 @@ import lcsb.mapviewer.model.map.MiriamRelationType;
import lcsb.mapviewer.model.map.MiriamType;
public class CopyPasteAbstractActionTest extends CdPluginFunctions {
private static Logger logger = LogManager.getLogger();
@Before
public void setUp() throws Exception {
......
......@@ -6,15 +6,12 @@ import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Test;
import jp.sbi.celldesigner.plugin.PluginSpeciesAlias;
import lcsb.mapviewer.cdplugin.CdPluginFunctions;
public class InfoFrameTest extends CdPluginFunctions {
private static Logger logger = LogManager.getLogger();
@Test
public void testSetEmptySpeciesList() {
......
......@@ -5,8 +5,6 @@ import static org.junit.Assert.assertEquals;
import java.util.Arrays;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Test;
import jp.sbi.celldesigner.plugin.PluginSpeciesAlias;
......@@ -14,7 +12,6 @@ import lcsb.mapviewer.cdplugin.CdPluginFunctions;
public class InfoPluginTest extends CdPluginFunctions {
private static Logger logger = LogManager.getLogger();
@Test
public void testConstructor() {
......
......@@ -61,24 +61,24 @@ import lcsb.mapviewer.persist.dao.cache.CacheTypeDao;
@RunWith(SpringJUnit4ClassRunner.class)
public abstract class AnnotationTestFunctions extends AbstractTransactionalJUnit4SpringContextTests {
private Logger logger = LogManager.getLogger();
protected static Logger logger = LogManager.getLogger();
private static int BLOCK_SIZE = 65536;
private static Map<String, Model> models = new HashMap<String, Model>();
@Rule
public UnitTestFailedWatcher unitTestFailedWatcher = new UnitTestFailedWatcher();
@Autowired
protected PermanentDatabaseLevelCacheInterface cache;
@Autowired
protected CacheTypeDao cacheTypeDao;
@Autowired
protected DbUtils dbUtils;
private MinervaLoggerAppender appender;
private String dapiLogin;
......
......@@ -4,8 +4,6 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -18,7 +16,6 @@ import lcsb.mapviewer.model.cache.CacheType;
public class ApplicationLevelCacheTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
private boolean status;
......
......@@ -22,8 +22,6 @@ import java.util.concurrent.ThreadFactory;
import org.apache.commons.net.ftp.FTPClient;
import org.apache.commons.net.ftp.FTPFile;
import org.apache.commons.net.ftp.FTPReply;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -42,7 +40,6 @@ import lcsb.mapviewer.persist.dao.cache.BigFileEntryDao;
public class BigFileCacheTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
private String ftpUrl = "ftp://ftp.informatik.rwth-aachen.de/README";
private String ftpUrlPartContent = "Welcome";
......
......@@ -8,8 +8,6 @@ import static org.mockito.Mockito.when;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -22,7 +20,6 @@ import lcsb.mapviewer.model.cache.CacheType;
import lcsb.mapviewer.persist.dao.cache.CacheTypeDao;
public class CachableInterfaceTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private List<CachableInterface> interfaces;
......
......@@ -5,8 +5,6 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
......@@ -19,7 +17,6 @@ import lcsb.mapviewer.common.exception.InvalidArgumentException;
import lcsb.mapviewer.model.cache.CacheType;
public class GeneralCacheTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
private GeneralCache cache = new GeneralCache(null);
......
......@@ -4,8 +4,6 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
......@@ -16,7 +14,6 @@ import lcsb.mapviewer.common.exception.InvalidArgumentException;
import lcsb.mapviewer.model.cache.CacheType;
public class GeneralCacheWithExclusionTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@AfterClass
public static void tearDownAfterClass() throws Exception {
......
......@@ -10,8 +10,6 @@ import static org.mockito.Mockito.when;
import java.util.Calendar;
import org.apache.commons.lang3.mutable.MutableBoolean;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -33,7 +31,6 @@ import lcsb.mapviewer.persist.dao.cache.CacheQueryDao;
@Rollback(true)
public class PermanentDatabaseLevelCacheTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private PermanentDatabaseLevelCacheInterface permanentDatabaseLevelCache;
......
......@@ -16,8 +16,6 @@ import java.util.List;
import java.util.Set;
import org.apache.commons.lang3.SerializationException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Test;
import org.mockito.Mockito;
import org.mockito.invocation.InvocationOnMock;
......@@ -43,7 +41,6 @@ import lcsb.mapviewer.model.map.MiriamRelationType;
import lcsb.mapviewer.model.map.MiriamType;
public class ChEMBLParserTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private GeneralCacheInterface cache;
......
......@@ -3,8 +3,6 @@ package lcsb.mapviewer.annotation.services;
import static org.junit.Assert.assertEquals;
import static org.junit.Assume.assumeTrue;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -17,7 +15,6 @@ import lcsb.mapviewer.annotation.services.dapi.DrugBankParser;
@ActiveProfiles("drugBankTestProfile")
public class DrugAnnotationTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private DrugBankParser drugBankParser;
......
......@@ -13,8 +13,6 @@ import java.io.IOException;
import java.util.List;
import org.apache.http.HttpStatus;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Test;
import org.mockito.Mockito;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -30,7 +28,6 @@ import lcsb.mapviewer.model.map.MiriamData;
import lcsb.mapviewer.model.map.MiriamType;
public class MeSHParserTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private MeSHParser meshParser;
......
......@@ -12,8 +12,6 @@ import java.util.HashSet;
import java.util.List;
import java.util.Set;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -35,7 +33,6 @@ import lcsb.mapviewer.persist.dao.ProjectDao;
import lcsb.mapviewer.persist.dao.user.UserDao;
public class MiRNAParserTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
protected ProjectDao projectDao;
......
......@@ -12,8 +12,6 @@ import static org.mockito.Mockito.when;
import java.io.IOException;
import java.lang.reflect.Field;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -30,7 +28,6 @@ import lcsb.mapviewer.model.map.MiriamRelationType;
import lcsb.mapviewer.model.map.MiriamType;
public class MiriamConnectorTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private MiriamConnector miriamConnector;
......
......@@ -15,8 +15,6 @@ import java.util.Map;
import java.util.Set;
import org.apache.commons.lang3.mutable.MutableDouble;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -44,7 +42,6 @@ import lcsb.mapviewer.model.user.UserClassAnnotators;
import lcsb.mapviewer.persist.dao.map.ModelDao;
public class ModelAnnotatorTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
private IProgressUpdater updater = new IProgressUpdater() {
@Override
public void setProgress(final double progress) {
......
......@@ -13,8 +13,6 @@ import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -35,7 +33,6 @@ import lcsb.mapviewer.model.Article;
public class PubmedParserTest extends AnnotationTestFunctions {
@Autowired
protected PermanentDatabaseLevelCacheInterface permanentDatabaseLevelCacheInterface;
private static Logger logger = LogManager.getLogger();
@Autowired
private PubmedParser pubmedParser;
private boolean status2;
......
......@@ -10,8 +10,6 @@ import static org.mockito.Mockito.when;
import java.io.IOException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Test;
import org.mockito.Mockito;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -25,7 +23,6 @@ import lcsb.mapviewer.model.map.MiriamData;
import lcsb.mapviewer.model.map.MiriamType;
public class TaxonomyBackendTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private TaxonomyBackend taxonomyBackend;
......
......@@ -8,8 +8,6 @@ import static org.mockito.Mockito.when;
import java.io.IOException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Ignore;
......@@ -26,7 +24,6 @@ import lcsb.mapviewer.model.map.species.GenericProtein;
import lcsb.mapviewer.model.map.species.Species;
public class BrendaAnnotatorTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private BrendaAnnotator brendaAnnotator;
......
......@@ -12,8 +12,6 @@ import static org.mockito.Mockito.when;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -41,7 +39,6 @@ import uk.ac.ebi.chebi.webapps.chebiWS.model.OntologyDataItem;
import uk.ac.ebi.chebi.webapps.chebiWS.model.SearchCategory;
public class ChebiAnnotatorTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private ChebiAnnotator backend;
......
......@@ -9,8 +9,6 @@ import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.AfterClass;
import org.junit.Test;
import org.junit.runner.RunWith;
......@@ -42,7 +40,6 @@ public class ElementAnnotatorImplementationsTest extends AnnotationTestFunctions
private static AnnotationConfigApplicationContext applicationContext;
@SuppressWarnings("unused")
private static Logger logger = LogManager.getLogger();
@Parameter
private String testName;
......
......@@ -10,8 +10,6 @@ import static org.mockito.Mockito.when;
import java.io.IOException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -32,7 +30,6 @@ import lcsb.mapviewer.model.map.MiriamType;
import lcsb.mapviewer.model.map.compartment.Compartment;
public class GoAnnotatorTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private GoAnnotator goAnnotator;
......
......@@ -12,8 +12,6 @@ import static org.mockito.Mockito.when;
import java.io.IOException;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -31,8 +29,6 @@ import lcsb.mapviewer.model.map.species.Species;
public class HgncAnnotatorTest extends AnnotationTestFunctions {
private final Logger logger = LogManager.getLogger();
@Autowired
private HgncAnnotator hgncAnnotator;
......
......@@ -11,8 +11,6 @@ import static org.mockito.Mockito.when;
import java.io.IOException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -30,7 +28,6 @@ import lcsb.mapviewer.model.map.species.SimpleMolecule;
import lcsb.mapviewer.model.map.species.Species;
public class ReconAnnotatorTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private ReconAnnotator reconAnnotator;
......
......@@ -10,8 +10,6 @@ import java.util.ArrayList;
import java.util.List;
import org.apache.commons.lang3.math.NumberUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Before;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -33,7 +31,6 @@ public class ChemicalParserTest extends AnnotationTestFunctions {
private final MiriamData parkinsonDiseaseId = new MiriamData(MiriamType.MESH_2012, "D010300");
private final MiriamData bloodLossDisease = new MiriamData(MiriamType.MESH_2012, "D016063");
private static Logger logger = LogManager.getLogger();
@Autowired
private ChemicalParser chemicalParser;
......
......@@ -3,8 +3,6 @@ package lcsb.mapviewer.annotation.services.dapi;
import static org.junit.Assert.assertEquals;
import static org.junit.Assume.assumeTrue;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Before;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -18,7 +16,6 @@ import lcsb.mapviewer.model.map.MiriamType;
@ActiveProfiles("dapiDownTestProfile")
public class DrugbankParserErrorHandlingTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private DrugBankParser drugBankParser;
......
......@@ -10,8 +10,6 @@ import static org.junit.Assume.assumeTrue;
import java.util.ArrayList;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Before;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -32,7 +30,6 @@ import lcsb.mapviewer.model.map.model.Model;
@ActiveProfiles("drugBankTestProfile")
@Rollback(true)
public class DrugbankParserTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private DrugBankParser drugBankParser;
......
......@@ -6,8 +6,6 @@ import static org.junit.Assume.assumeTrue;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.Before;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -22,7 +20,6 @@ import lcsb.mapviewer.model.map.MiriamType;
@ActiveProfiles("dapiNotConnectedTestProfile")
@Rollback(true)
public class DrugbankParserWithNoConnectionTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private DrugBankParser drugBankParser;
......
......@@ -22,8 +22,6 @@ import java.util.concurrent.Future;
import org.apache.commons.net.ftp.FTPClient;
import org.apache.commons.net.ftp.FTPFile;
import org.apache.commons.net.ftp.FTPReply;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
......@@ -51,7 +49,6 @@ import lcsb.mapviewer.persist.dao.map.layout.ReferenceGenomeDao;
public class UcscReferenceGenomeConnectorTest extends AnnotationTestFunctions {
private static Logger logger = LogManager.getLogger();
@Autowired
private UcscReferenceGenomeConnector connector;
......
......@@ -2,6 +2,8 @@ package lcsb.mapviewer.common;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.apache.logging.log4j.core.LogEvent;
import org.junit.After;
import org.junit.Before;
......@@ -9,6 +11,8 @@ import org.junit.Rule;
public class CommonTestFunctions {
protected static Logger logger = LogManager.getLogger();
@Rule
public UnitTestFailedWatcher ruleExample = new UnitTestFailedWatcher();
......