in cmd/ip-masq-agent-v2/testing/fakefs/fakefs.go [70:82]
func (fs StringFS) ReadFile(name string) ([]byte, error) {
for _, file := range fs.Files {
if strings.EqualFold(filepath.Join(file.Path, file.Name), name) {
return []byte(file.Content), nil
}
}
return nil, &os.PathError{
Op: "open",
Path: name,
Err: errors.New("errno 2"), // errno 2 is ENOENT, since the file shouldn't exist
}
}