[tor-commits] [collector/master] Add test that will fail #23981.

karsten at torproject.org karsten at torproject.org
Thu Oct 26 08:12:43 UTC 2017


commit 3a95892de3bb4728a45812b2cc2ed9d24a7de33e
Author: Karsten Loesing <karsten.loesing at gmx.net>
Date:   Wed Oct 25 16:45:38 2017 +0200

    Add test that will fail #23981.
---
 .../collector/bridgedescs/SanitizedBridgesWriterTest.java  | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/src/test/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriterTest.java b/src/test/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriterTest.java
index 0e62573..3afe9cb 100644
--- a/src/test/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriterTest.java
+++ b/src/test/java/org/torproject/collector/bridgedescs/SanitizedBridgesWriterTest.java
@@ -440,6 +440,20 @@ public class SanitizedBridgesWriterTest {
   }
 
   @Test
+  public void testServerDescriptorPublishedLineAfterFingerprintLine()
+      throws Exception {
+    this.configuration.setProperty(Key.ReplaceIpAddressesWithHashes.name(),
+        "true");
+    String fingerprintLine =
+        "fingerprint 46D4 A711 97B8 FA51 5A82 6C6B 017C 522F E264 655B";
+    this.defaultServerDescriptorBuilder.removeLine(fingerprintLine);
+    this.defaultServerDescriptorBuilder.insertBeforeLineStartingWith(
+        "published ", Arrays.asList(fingerprintLine));
+    this.runTest();
+    assertFalse(this.parsedServerDescriptors.isEmpty());
+  }
+
+  @Test
   public void testExtraInfoDescriptorDefault() throws Exception {
     this.runTest();
     List<String> expectedLines = Arrays.asList(





More information about the tor-commits mailing list