func coverToolInstalled() bool { working := getWorkDir() command := system.NewCommand(working, "go", "tool", "cover").Execute() installed := strings.Contains(command.Output, "Usage of 'go tool cover':") if !installed { log.Print(coverToolMissing) return false } return true }
func coverToolInstalled() bool { working, err := os.Getwd() if err != nil { working = "." } command := system.NewCommand(working, "go", "tool", "cover").Execute() installed := strings.Contains(command.Output, "Usage of 'go tool cover':") if !installed { log.Print(coverToolMissing) return false } return true }