[tor-commits] [meek/master] Array syntax looks weird, just use a slice.

dcf at torproject.org dcf at torproject.org
Tue Oct 4 02:11:33 UTC 2016


commit ff9476e53f3462d5ed25acbd4d348293164bdfae
Author: David Fifield <david at bamsoftware.com>
Date:   Mon Oct 3 18:58:50 2016 -0700

    Array syntax looks weird, just use a slice.
---
 meek-client/helper_test.go | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meek-client/helper_test.go b/meek-client/helper_test.go
index 5838966..b349a49 100644
--- a/meek-client/helper_test.go
+++ b/meek-client/helper_test.go
@@ -6,7 +6,7 @@ import (
 )
 
 func TestMakeProxySpec(t *testing.T) {
-	badTests := [...]*url.URL{
+	badTests := []*url.URL{
 		{Scheme: "http"},
 		{Scheme: "http", Host: ":"},
 		{Scheme: "http", Host: "localhost"},
@@ -26,7 +26,7 @@ func TestMakeProxySpec(t *testing.T) {
 		{Scheme: "socks4", Host: "localhost:1080"},
 		{Scheme: "unknown", Host: "localhost:9999"},
 	}
-	goodTests := [...]struct {
+	goodTests := []struct {
 		input    *url.URL
 		expected ProxySpec
 	}{





More information about the tor-commits mailing list