Thread

Commits

  1. Add regression tests for psql \g piped into a program

  2. Add regression tests for psql's \o and \g on files

  1. TAP tests for psql \g piped into program

    Daniel Verite <daniel@manitou-mail.org> — 2023-01-02T21:32:03Z

    Hi,
    
    This is a follow-up to commit d2a44904 from the 2022-11 CF [1]
    The TAP tests were left out with the suggestion to use Perl instead of
    cat (Unix) / findstr (Windows) as the program to pipe into.
    
    PFA a patch implementing that suggestion.
    
    
    [1] https://commitfest.postgresql.org/40/4000/
    
    Best regards,
    -- 
    Daniel Vérité
    https://postgresql.verite.pro/
    Twitter: @DanielVerite
    
  2. Re: TAP tests for psql \g piped into program

    Peter Eisentraut <peter.eisentraut@enterprisedb.com> — 2023-03-08T15:13:44Z

    On 02.01.23 22:32, Daniel Verite wrote:
    > This is a follow-up to commit d2a44904 from the 2022-11 CF [1]
    > The TAP tests were left out with the suggestion to use Perl instead of
    > cat (Unix) / findstr (Windows) as the program to pipe into.
    > 
    > PFA a patch implementing that suggestion.
    
    The perl binary refactoring in this patch caught my attention, since I 
    ran into this issue in another patch as well.  I'm always happy to 
    consider a refactoring, but I think in this case I wouldn't do it.
    
    If you grep for PostgreSQL::Test::Utils::windows_os, you'll find quite a 
    few pieces of code that somehow fix up paths for Windows.  By hiding the 
    Perl stuff in a function, we give the illusion that you don't have to 
    worry about it and it's all taken care of in the test library.  But you 
    have to worry about it in the very next line in 
    025_stuck_on_old_timeline.pl!  We should handle this all on the same 
    level: either in the test code or in the test library.  It would be 
    useful to work toward a general "prepare path for shell" routine.  But 
    until we have that, I don't think this is sufficient progress.
    
    So for your patch, I would just do the path adjustment ad hoc in-line. 
    It's just one additional line.
    
    
    
    
    
  3. Re: TAP tests for psql \g piped into program

    Daniel Verite <daniel@manitou-mail.org> — 2023-03-29T18:39:00Z

    	Peter Eisentraut wrote:
    
    > So for your patch, I would just do the path adjustment ad hoc in-line. 
    > It's just one additional line.
    
    Here's the patch updated that way.
    
    
    Best regards,
    -- 
    Daniel Vérité
    https://postgresql.verite.pro/
    Twitter: @DanielVerite
    
  4. Re: TAP tests for psql \g piped into program

    Heikki Linnakangas <hlinnaka@iki.fi> — 2023-10-02T08:46:48Z

    On 29/03/2023 21:39, Daniel Verite wrote:
    > Peter Eisentraut wrote:
    > 
    >> So for your patch, I would just do the path adjustment ad hoc in-line.
    >> It's just one additional line.
    > 
    > Here's the patch updated that way.
    
    Committed, thanks!
    
    -- 
    Heikki Linnakangas
    Neon (https://neon.tech)