git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCHv2 2/2] tests: make the 'test_pause' helper work in non-verbose mode

From
Jeff King <peff@peff.net>
Date
Mar 20, 2017, 04:32 UTC
Message-ID
<20170320043219.3y4ksmttvcchfpis@sigill.intra.peff.net>
In-Reply-To
<20170318161400.19753-2-szeder.dev@gmail.com>
On Sat, Mar 18, 2017 at 05:14:00PM +0100, SZEDER Gábor wrote:
Show 15 quoted lines
> When the 'test_pause' helper function invokes the shell mid-test, it
> explicitly redirects the shell's stdout and stderr to file descriptors
> 3 and 4, which are the stdout and stderr of the tests (i.e. where they
> would be connected anyway without those redirections).  These file
> descriptors are only attached to the terminal in verbose mode, hence
> the restriction of 'test_pause' to work only with '-v'.
> 
> Redirect the shell's stdout and stderr to the test environment's
> original stdout and stderr, allowing it to work properly even in
> non-verbose mode, and the restriction can be lifted.
> 
> Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
> ---
>  t/test-lib-functions.sh | 9 ++-------
>  1 file changed, 2 insertions(+), 7 deletions(-)
This makes sense, too. Thanks.
-Peff
Previous: SZEDER GáborNext: Jeff King
Message 6 of 9 in “tests: create an interactive gdb session with the 'debug' helper”
  1. tests: create an interactive gdb session with the 'debug' helperSZEDER Gábor, Mar 17, 2017
  2. Jeff KingMar 17, 2017
  3. SZEDER GáborMar 18, 2017
  4. 1/2 tests: create an interactive gdb session with the 'debug' helperSZEDER Gábor, Mar 18, 2017
  5. 2/2 tests: make the 'test_pause' helper work in non-verbose modeSZEDER Gábor, Mar 18, 2017
  6. Jeff KingMar 20, 2017
  7. Jeff KingMar 20, 2017
  8. Johannes SchindelinMar 21, 2017
  9. Jeff KingMar 20, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.