in reply to Re: Outputting input prompt with prove
in thread Outputting input prompt with prove

I’m not sure how I could avoid getting input from the user. Is there a way to inject input automatically?

  • Comment on Re^2: Outputting input prompt with prove

Replies are listed 'Best First'.
Re^3: Outputting input prompt with prove
by Corion (Patriarch) on Aug 05, 2019 at 05:55 UTC

    Did you write the test program? Then rewrite it so it doesn't need interactive input.

    If you didn't write the test program and cannot change it, don't use prove with it or learn that you need to type the input blindly.

    Maybe you can write a wrapper for test that writes the input you want to it and passes its output through, maybe using IPC::Run3.