()
| 185 | } |
| 186 | |
| 187 | func stopNodes() { |
| 188 | var wg sync.WaitGroup |
| 189 | |
| 190 | for _, nodeCmd := range nodeCmds { |
| 191 | wg.Add(1) |
| 192 | go func(thisCmd *utils.CMD) { |
| 193 | defer wg.Done() |
| 194 | thisCmd.Cmd.Process.Signal(syscall.SIGTERM) |
| 195 | thisCmd.Cmd.Wait() |
| 196 | grepRace := exec.Command("/bin/sh", "-c", "grep -a -A 50 'DATA RACE' "+thisCmd.LogPath) |
| 197 | out, _ := grepRace.Output() |
| 198 | if len(out) > 2 { |
| 199 | log.Fatal(string(out)) |
| 200 | } |
| 201 | }(nodeCmd) |
| 202 | } |
| 203 | |
| 204 | wg.Wait() |
| 205 | } |
| 206 | |
| 207 | func getJSON(pattern string, args ...interface{}) (result *jsonq.JsonQuery, err error) { |
| 208 | url := "http://localhost:4663/" + apiProxyPrefix + "/" + fmt.Sprintf(pattern, args...) |
no test coverage detected