1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00

Do not quite when pumactl unexpectedly exits.

When `pumactl` encounters issue, it exits [[1]]. That way also the whole
test suite unexpectedly exits. Rescuing `SystemExit` exception keeps the
test suite finish.

Fixes #2329

[1]: 0f718d516b/lib/puma/control_cli.rb (L272)
This commit is contained in:
Vít Ondruch 2020-08-07 12:52:31 +02:00
parent 0f718d516b
commit aebca2b3d7

View file

@ -178,7 +178,10 @@ class TestPumaControlCli < TestConfigFileBase
def assert_command_cli_output(options, expected_out)
cmd = Puma::ControlCLI.new(options)
out, _ = capture_subprocess_io do
cmd.run
begin
cmd.run
rescue SystemExit => e
end
end
assert_match expected_out, out
end