2
2
mirror of https://github.com/octoleo/restic.git synced 2024-11-26 14:56:29 +00:00

rest: Remove unneeded tempdir

This commit is contained in:
Alexander Neumann 2018-01-20 10:13:04 +01:00
parent 663e8284b2
commit 1046eabf95

View File

@ -2,7 +2,6 @@ package rest_test
import ( import (
"context" "context"
"io/ioutil"
"net" "net"
"net/url" "net/url"
"os" "os"
@ -70,13 +69,6 @@ func newTestSuite(ctx context.Context, t testing.TB) *test.Suite {
return &test.Suite{ return &test.Suite{
// NewConfig returns a config for a new temporary backend that will be used in tests. // NewConfig returns a config for a new temporary backend that will be used in tests.
NewConfig: func() (interface{}, error) { NewConfig: func() (interface{}, error) {
dir, err := ioutil.TempDir(rtest.TestTempDir, "restic-test-rest-")
if err != nil {
t.Fatal(err)
}
t.Logf("create new backend at %v", dir)
url, err := url.Parse("http://localhost:8000/restic-test") url, err := url.Parse("http://localhost:8000/restic-test")
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)