diff --git a/test/cli_test.rb b/test/cli_test.rb index 52e98d4..ef056a4 100644 --- a/test/cli_test.rb +++ b/test/cli_test.rb @@ -79,8 +79,8 @@ def test_no_yaml def test_version_flag read, write = IO.pipe # optparse --version immediately call exit so we test in a subprocess - pid = fork do - STDOUT.reopen(write) + pid = fork do + $stdout.reopen(write) read.close exit(CLI.new(["--version"]).run) end