(pid int, fn func(), u *User)
| 38 | } |
| 39 | |
| 40 | func createMockRequest(pid int, fn func(), u *User) { |
| 41 | fmt.Println("UserID:", u.ID, "\tProcess", pid, "started.") |
| 42 | res := HandleRequest(fn, u) |
| 43 | |
| 44 | if res { |
| 45 | fmt.Println("UserID:", u.ID, "\tProcess", pid, "done.") |
| 46 | } else { |
| 47 | fmt.Println("UserID:", u.ID, "\tProcess", pid, "killed. (No quota left)") |
| 48 | } |
| 49 | |
| 50 | wg.Done() |
| 51 | } |
| 52 | |
| 53 | func shortProcess() { |
| 54 | time.Sleep(6 * time.Second) |
no test coverage detected