Get rid of the latest ioutil bits
This commit is contained in:
parent
3f23ff5c08
commit
5f88a9146c
|
@ -97,7 +97,7 @@ disabled_server_names = []
|
||||||
force_tcp = false
|
force_tcp = false
|
||||||
|
|
||||||
|
|
||||||
## Enable support for HTTP/3 (DoH3, HTTP over QUIC)
|
## Enable *experimental* support for HTTP/3 (DoH3, HTTP over QUIC)
|
||||||
## Note that, like DNSCrypt but unlike other HTTP versions, this uses
|
## Note that, like DNSCrypt but unlike other HTTP versions, this uses
|
||||||
## UDP and (usually) port 443 instead of TCP.
|
## UDP and (usually) port 443 instead of TCP.
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,6 @@ package main
|
||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"fmt"
|
"fmt"
|
||||||
"io/ioutil"
|
|
||||||
"net/http"
|
"net/http"
|
||||||
"net/http/httptest"
|
"net/http/httptest"
|
||||||
"net/url"
|
"net/url"
|
||||||
|
@ -134,7 +133,7 @@ func loadSnakeoil(t *testing.T, d *SourceTestData) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func loadTestSourceNames(t *testing.T, d *SourceTestData) {
|
func loadTestSourceNames(t *testing.T, d *SourceTestData) {
|
||||||
files, err := ioutil.ReadDir(filepath.Join("testdata", "sources"))
|
files, err := os.ReadDir(filepath.Join("testdata", "sources"))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Fatalf("Unable to load list of test sources: %v", err)
|
t.Fatalf("Unable to load list of test sources: %v", err)
|
||||||
}
|
}
|
||||||
|
@ -196,7 +195,7 @@ func loadFixtures(t *testing.T, d *SourceTestData) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func makeTempDir(t *testing.T, d *SourceTestData) {
|
func makeTempDir(t *testing.T, d *SourceTestData) {
|
||||||
name, err := ioutil.TempDir("", "sources_test.go."+t.Name())
|
name, err := os.MkdirTemp("", "sources_test.go."+t.Name())
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Fatalf("Unable to create temporary directory: %v", err)
|
t.Fatalf("Unable to create temporary directory: %v", err)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue