[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/master] Add another unit test for parse_bridge_line().



commit 1ec4d52e593035aee0d59016c8c8dec6a4561b00
Author: George Kadianakis <desnacked@xxxxxxxxxx>
Date:   Fri Apr 11 21:06:40 2014 +0300

    Add another unit test for parse_bridge_line().
---
 src/test/test_config.c |   17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/src/test/test_config.c b/src/test/test_config.c
index 3a1e6cb..dbb5079 100644
--- a/src/test/test_config.c
+++ b/src/test/test_config.c
@@ -421,6 +421,23 @@ test_config_parse_bridge_line(void *arg)
     smartlist_free(sl_tmp);
   }
 
+  {
+    smartlist_t *sl_tmp = smartlist_new();
+    smartlist_add_asprintf(sl_tmp, "dub=come");
+    smartlist_add_asprintf(sl_tmp, "save=me");
+
+    good_bridge_line_test("transport 192.0.2.1:12 "
+                          "4352e58420e68f5e40bf7c74faddccd9d1349666 "
+                          "dub=come save=me",
+
+                          "192.0.2.1:12",
+                          "4352e58420e68f5e40bf7c74faddccd9d1349666",
+                          "transport", sl_tmp);
+
+    SMARTLIST_FOREACH(sl_tmp, char *, s, tor_free(s));
+    smartlist_free(sl_tmp);
+  }
+
   good_bridge_line_test("192.0.2.1:1231 "
                         "4352e58420e68f5e40bf7c74faddccd9d1349413",
                         "192.0.2.1:1231",



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits