Conditions | 3 |
Total Lines | 12 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | package cmd |
||
38 | func buildResultViewCmd(out io.Writer) func(cmd *cobra.Command, args []string) error { |
||
39 | return func(cmd *cobra.Command, args []string) error { |
||
40 | resultFilePath := cmd.Flag(flagResultFile).Value.String() |
||
41 | |||
42 | results, err := result.LoadResultsFromFile(resultFilePath) |
||
43 | if err != nil { |
||
44 | return errors.Wrapf(err, "failed to load results from %s", resultFilePath) |
||
45 | } |
||
46 | |||
47 | tree.NewResultTreePrinter().Print(results, out) |
||
48 | |||
49 | return nil |
||
50 | } |
||
52 |