From: Matt Joiner Date: Tue, 4 Aug 2015 16:38:36 +0000 (+1000) Subject: Invalid test X-Git-Tag: v1.0.0~1079 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=19021f1360a57004f26caae084e2230332eca122;p=btrtrc.git Invalid test The function is never exposed publicly or called without holding the client lock. --- diff --git a/torrent_test.go b/torrent_test.go index 6134e28d..bca6f775 100644 --- a/torrent_test.go +++ b/torrent_test.go @@ -1,7 +1,6 @@ package torrent import ( - "sync" "testing" "github.com/anacrolix/torrent/peer_protocol" @@ -43,22 +42,6 @@ func TestTorrentRequest(t *testing.T) { } } -func TestTorrentDoubleClose(t *testing.T) { - tt, err := newTorrent(InfoHash{}) - if err != nil { - t.Fatal(err) - } - wg := sync.WaitGroup{} - for i := 0; i < 2; i++ { - wg.Add(1) - go func() { - tt.close() - wg.Done() - }() - } - wg.Wait() -} - func TestAppendToCopySlice(t *testing.T) { orig := []int{1, 2, 3} dupe := append([]int{}, orig...)