Re: [PATCHv2 2/2] tests: make the 'test_pause' helper work in non-verbose mode
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