commit 7cc1d9d9704f9efbf28e2f83d9dee959ceae82ce Author: Karsten Loesing karsten.loesing@gmx.net Date: Thu Jul 14 14:08:34 2016 +0200
Let Eclipse organize imports. --- src/main/java/org/torproject/collector/Main.java | 1 - .../collector/bridgedescs/BridgeSnapshotReader.java | 1 - .../collector/bridgedescs/SanitizedBridgesWriter.java | 1 - .../org/torproject/collector/conf/Configuration.java | 5 ----- .../torproject/collector/index/CreateIndexJson.java | 3 --- .../collector/relaydescs/ArchiveReader.java | 1 - .../collector/relaydescs/ArchiveWriter.java | 1 - .../relaydescs/CachedRelayDescriptorReader.java | 2 -- .../relaydescs/RelayDescriptorDownloader.java | 1 - .../collector/relaydescs/RelayDescriptorParser.java | 1 - .../collector/torperf/TorperfDownloader.java | 1 - src/test/java/org/torproject/collector/MainTest.java | 19 ++++--------------- .../torproject/collector/conf/ConfigurationTest.java | 11 +++-------- 13 files changed, 7 insertions(+), 41 deletions(-)
diff --git a/src/main/java/org/torproject/collector/Main.java b/src/main/java/org/torproject/collector/Main.java index 34bb95b..81234c3 100644 --- a/src/main/java/org/torproject/collector/Main.java +++ b/src/main/java/org/torproject/collector/Main.java @@ -18,7 +18,6 @@ import java.io.FileInputStream; import java.io.IOException; import java.lang.reflect.InvocationTargetException; import java.nio.file.Files; -import java.nio.file.Paths; import java.nio.file.StandardCopyOption; import java.util.HashMap; import java.util.Map; diff --git a/src/main/java/org/torproject/collector/bridgedescs/BridgeSnapshotReader.java b/src/main/java/org/torproject/collector/bridgedescs/BridgeSnapshotReader.java index 169731b..3df5242 100644 --- a/src/main/java/org/torproject/collector/bridgedescs/BridgeSnapshotReader.java +++ b/src/main/java/org/torproject/collector/bridgedescs/BridgeSnapshotReader.java @@ -7,7 +7,6 @@ import org.apache.commons.codec.binary.Hex; import org.apache.commons.codec.digest.DigestUtils; import org.apache.commons.compress.archivers.tar.TarArchiveInputStream; import org.apache.commons.compress.compressors.gzip.GzipCompressorInputStream; - import org.slf4j.Logger; import org.slf4j.LoggerFactory;
diff --git a/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java b/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java index b1b9589..9d5828c 100644 --- a/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java +++ b/src/main/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriter.java @@ -12,7 +12,6 @@ import org.apache.commons.codec.DecoderException; import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.binary.Hex; import org.apache.commons.codec.digest.DigestUtils; - import org.slf4j.Logger; import org.slf4j.LoggerFactory;
diff --git a/src/main/java/org/torproject/collector/conf/Configuration.java b/src/main/java/org/torproject/collector/conf/Configuration.java index 2166402..4e05ad4 100644 --- a/src/main/java/org/torproject/collector/conf/Configuration.java +++ b/src/main/java/org/torproject/collector/conf/Configuration.java @@ -3,13 +3,8 @@
package org.torproject.collector.conf;
-import java.io.IOException; -import java.net.MalformedURLException; -import java.net.URL; import java.nio.file.Path; import java.nio.file.Paths; -import java.util.Arrays; -import java.util.List; import java.util.Properties;
/** diff --git a/src/main/java/org/torproject/collector/index/CreateIndexJson.java b/src/main/java/org/torproject/collector/index/CreateIndexJson.java index a39ef67..821be59 100644 --- a/src/main/java/org/torproject/collector/index/CreateIndexJson.java +++ b/src/main/java/org/torproject/collector/index/CreateIndexJson.java @@ -13,9 +13,6 @@ import com.google.gson.GsonBuilder; import org.apache.commons.compress.compressors.bzip2.BZip2CompressorOutputStream; import org.apache.commons.compress.compressors.xz.XZCompressorOutputStream;
-import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - import java.io.BufferedWriter; import java.io.File; import java.io.FileOutputStream; diff --git a/src/main/java/org/torproject/collector/relaydescs/ArchiveReader.java b/src/main/java/org/torproject/collector/relaydescs/ArchiveReader.java index 25f5859..9ceb2a0 100644 --- a/src/main/java/org/torproject/collector/relaydescs/ArchiveReader.java +++ b/src/main/java/org/torproject/collector/relaydescs/ArchiveReader.java @@ -6,7 +6,6 @@ package org.torproject.collector.relaydescs; import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.digest.DigestUtils; import org.apache.commons.compress.compressors.bzip2.BZip2CompressorInputStream; - import org.slf4j.Logger; import org.slf4j.LoggerFactory;
diff --git a/src/main/java/org/torproject/collector/relaydescs/ArchiveWriter.java b/src/main/java/org/torproject/collector/relaydescs/ArchiveWriter.java index 3715a9f..db05bc5 100644 --- a/src/main/java/org/torproject/collector/relaydescs/ArchiveWriter.java +++ b/src/main/java/org/torproject/collector/relaydescs/ArchiveWriter.java @@ -30,7 +30,6 @@ import java.util.Arrays; import java.util.Date; import java.util.HashMap; import java.util.HashSet; -import java.util.List; import java.util.Map; import java.util.Set; import java.util.SortedMap; diff --git a/src/main/java/org/torproject/collector/relaydescs/CachedRelayDescriptorReader.java b/src/main/java/org/torproject/collector/relaydescs/CachedRelayDescriptorReader.java index 6c18cdb..05d4481 100644 --- a/src/main/java/org/torproject/collector/relaydescs/CachedRelayDescriptorReader.java +++ b/src/main/java/org/torproject/collector/relaydescs/CachedRelayDescriptorReader.java @@ -5,7 +5,6 @@ package org.torproject.collector.relaydescs;
import org.apache.commons.codec.binary.Hex; import org.apache.commons.codec.digest.DigestUtils; - import org.slf4j.Logger; import org.slf4j.LoggerFactory;
@@ -23,7 +22,6 @@ import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Arrays; import java.util.HashSet; -import java.util.List; import java.util.Set; import java.util.SortedSet; import java.util.Stack; diff --git a/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorDownloader.java b/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorDownloader.java index efe4676..f4e38f4 100644 --- a/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorDownloader.java +++ b/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorDownloader.java @@ -5,7 +5,6 @@ package org.torproject.collector.relaydescs;
import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.digest.DigestUtils; - import org.slf4j.Logger; import org.slf4j.LoggerFactory;
diff --git a/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorParser.java b/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorParser.java index 946a494..8c44c38 100644 --- a/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorParser.java +++ b/src/main/java/org/torproject/collector/relaydescs/RelayDescriptorParser.java @@ -6,7 +6,6 @@ package org.torproject.collector.relaydescs; import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.binary.Hex; import org.apache.commons.codec.digest.DigestUtils; - import org.slf4j.Logger; import org.slf4j.LoggerFactory;
diff --git a/src/main/java/org/torproject/collector/torperf/TorperfDownloader.java b/src/main/java/org/torproject/collector/torperf/TorperfDownloader.java index 25164c9..dd1c541 100644 --- a/src/main/java/org/torproject/collector/torperf/TorperfDownloader.java +++ b/src/main/java/org/torproject/collector/torperf/TorperfDownloader.java @@ -23,7 +23,6 @@ import java.net.URL; import java.text.SimpleDateFormat; import java.util.Arrays; import java.util.HashMap; -import java.util.List; import java.util.Map; import java.util.SortedMap; import java.util.Stack; diff --git a/src/test/java/org/torproject/collector/MainTest.java b/src/test/java/org/torproject/collector/MainTest.java index a948070..5991f78 100644 --- a/src/test/java/org/torproject/collector/MainTest.java +++ b/src/test/java/org/torproject/collector/MainTest.java @@ -2,35 +2,24 @@ * See LICENSE for licensing information */ package org.torproject.collector;
-import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertTrue; -import static org.junit.Assert.assertFalse; import static org.junit.Assert.fail;
import org.torproject.collector.conf.Key; -import org.torproject.collector.conf.ConfigurationException;
-import java.io.ByteArrayInputStream; -import java.io.File; -import java.net.URL; +import org.junit.Rule; +import org.junit.Test; +import org.junit.rules.TemporaryFolder; + import java.io.BufferedWriter; import java.io.File; import java.nio.file.Files; -import java.nio.file.Path; -import java.nio.file.Paths; -import java.security.AccessControlException; -import java.security.Policy; -import java.util.Arrays; import java.util.List; import java.util.Properties; import java.util.Random;
-import org.junit.rules.TemporaryFolder; -import org.junit.Rule; -import org.junit.Test; - public class MainTest {
private Random randomSource = new Random(); diff --git a/src/test/java/org/torproject/collector/conf/ConfigurationTest.java b/src/test/java/org/torproject/collector/conf/ConfigurationTest.java index 2ecbe00..f966b43 100644 --- a/src/test/java/org/torproject/collector/conf/ConfigurationTest.java +++ b/src/test/java/org/torproject/collector/conf/ConfigurationTest.java @@ -4,21 +4,16 @@ package org.torproject.collector.conf;
import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertTrue; + +import org.junit.Test;
import java.io.ByteArrayInputStream; import java.io.File; -import java.net.URL; -import java.nio.file.Path; -import java.nio.file.Paths; import java.util.Arrays; -import java.util.List; import java.util.Random;
-import org.junit.Test; - public class ConfigurationTest {
private Random randomSource = new Random();
tor-commits@lists.torproject.org