From 706780000531d0cd98e764c52b85e85ab0929ea5 Mon Sep 17 00:00:00 2001 From: Dimitri Sokolyuk Date: Sat, 15 Dec 2018 15:50:36 +0100 Subject: move testdata to packages --- meta/torrent_test.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'meta/torrent_test.go') diff --git a/meta/torrent_test.go b/meta/torrent_test.go index f03142f..710d178 100644 --- a/meta/torrent_test.go +++ b/meta/torrent_test.go @@ -3,14 +3,14 @@ package meta import "testing" var tors = map[string]string{ - "bsd": "OpenBSD_5.9_amd64_install59.iso-2016-03-29-0449.torrent", - "ogg": "OpenBSD_songs_ogg-2016-03-25-0127.torrent", - "deb": "debian-8.5.0-amd64-netinst.iso.torrent", - "mul": "multi.torrent", + "bsd": "testdata/OpenBSD_5.9_amd64_install59.iso-2016-03-29-0449.torrent", + "ogg": "testdata/OpenBSD_songs_ogg-2016-03-25-0127.torrent", + "deb": "testdata/debian-8.5.0-amd64-netinst.iso.torrent", + "mul": "testdata/multi.torrent", } func TestHash(t *testing.T) { - tor, err := New("../testdata/" + tors["bsd"]) + tor, err := New(tors["bsd"]) if err != nil { t.Error(err) } @@ -20,7 +20,7 @@ func TestHash(t *testing.T) { } func TestPieces(t *testing.T) { - tor, err := New("../testdata/" + tors["mul"]) + tor, err := New(tors["mul"]) if err != nil { t.Error(err) } @@ -31,7 +31,7 @@ func TestPieces(t *testing.T) { } func TestPieces2(t *testing.T) { - tor, err := New("../testdata/" + tors["mul"]) + tor, err := New(tors["mul"]) if err != nil { t.Error(err) } @@ -42,7 +42,7 @@ func TestPieces2(t *testing.T) { func TestReadAt(t *testing.T) { t.Skip() - tor, err := New("../testdata/" + tors["bsd"]) + tor, err := New(tors["bsd"]) if err != nil { t.Error(err) } -- cgit v1.2.3