MCPcopy
hub / github.com/nextdns/nextdns / readFile

Function readFile

host/service/config_test.go:47–54  ·  view source on GitHub ↗

readFile reads the content of a file as a string.

(t *testing.T, path string)

Source from the content-addressed store, hash-verified

45
46// readFile reads the content of a file as a string.
47func readFile(t *testing.T, path string) string {
48 t.Helper()
49 b, err := os.ReadFile(path)
50 if err != nil {
51 t.Fatal(err)
52 }
53 return string(b)
54}
55
56func Test_splitInlineComment(t *testing.T) {
57 tests := []struct {

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…