def METHOD_NAME(self, remote_get_wal_mock, capsys, tmpdir):
    """Verifies non-255 SSH exit codes are passed through."""
    mock_ssh_process = remote_get_wal_mock.return_value
    mock_ssh_process.returncode = 1
    dest_path = tmpdir.join("dummy_dest").strpath
    with pytest.raises(SystemExit) as exc:
        walrestore.main(["a.host", "a-server", "dummy_wal", dest_path])
    assert exc.value.code == 1
    out, err = capsys.readouterr()
    assert not out
    assert ("ERROR: Remote 'barman get-wal' command has failed!\n") in err