update golangci-lint and replace deprecated calls to io/ioutil

This commit is contained in:
Markus Muellner
2022-09-22 17:18:14 +02:00
committed by Benj Fassbind
parent 71fd730598
commit 352f4e8772
23 changed files with 30 additions and 52 deletions
+1 -2
View File
@@ -3,7 +3,6 @@ package http
import (
"context"
"fmt"
"io/ioutil"
"net"
"net/http"
"os"
@@ -26,7 +25,7 @@ type GrabDownloaderSuiteBase struct {
}
func (s *GrabDownloaderSuiteBase) SetUpTest(c *C) {
s.tempfile, _ = ioutil.TempFile(os.TempDir(), "aptly-test")
s.tempfile, _ = os.CreateTemp(os.TempDir(), "aptly-test")
s.l, _ = net.ListenTCP("tcp4", &net.TCPAddr{IP: net.IPv4(127, 0, 0, 1)})
s.url = fmt.Sprintf("http://localhost:%d", s.l.Addr().(*net.TCPAddr).Port)