Exists(t *testing.T) {  // save log output into buf for testing  var buf bytes.Buffer  log.SetOutput(&buf)  // mock and defer restore osStat  osStatOrig := osStat  defer func() {   log.SetOutput(os.Stderr)   osStat = osStatOrig  }()  cases := []struct {   name           string   isDir          bool   osStatErr      error   logContainsSeq []string   want           bool  }{   {    name:           "