Skip to content

Commit

Permalink
fix(cli/js): improve resource sanitizer messages (#16798)
Browse files Browse the repository at this point in the history
This commit improves the guidance for how to close a child process
stdout / stderr to also include guidance for when using
`new Deno.Command()`.
  • Loading branch information
lucacasonato committed Nov 25, 2022
1 parent 433f380 commit 3f79c9b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cli/js/40_testing.js
Expand Up @@ -314,7 +314,7 @@
case "httpConn":
return "Close the inbound HTTP connection by calling `httpConn.close()`.";
case "httpStream":
return "Close the inbound HTTP request by responding with `e.respondWith().` or closing the HTTP connection.";
return "Close the inbound HTTP request by responding with `e.respondWith()` or closing the HTTP connection.";
case "tcpStream":
return "Close the TCP connection by calling `tcpConn.close()`.";
case "unixStream":
Expand Down Expand Up @@ -344,9 +344,9 @@
case "childStdin":
return "Close the child process stdin by calling `proc.stdin.close()`.";
case "childStdout":
return "Close the child process stdout by calling `proc.stdout.close()`.";
return "Close the child process stdout by calling `proc.stdout.close()` or `await child.stdout.cancel()`.";
case "childStderr":
return "Close the child process stderr by calling `proc.stderr.close()`.";
return "Close the child process stderr by calling `proc.stderr.close()` or `await child.stderr.cancel()`.";
case "child":
return "Close the child process by calling `proc.kill()` or `proc.close()`.";
case "signal":
Expand Down

0 comments on commit 3f79c9b

Please sign in to comment.