def METHOD_NAME(
    mock_sub,
    capsys,
    platform,
    start_new_session,
    popen_kwargs,
    sub_kw,
):
    """start_new_session is passed thru on Linux and macOS but converted for Windows."""
    mock_sub.tools.host_os = platform
    mock_sub.Popen(["hello", "world"], start_new_session=start_new_session)
    final_kwargs = {**sub_kw, **popen_kwargs}
    if platform == "Windows":
        mock_sub._subprocess.Popen.assert_called_with(
            ["hello", "world"], **final_kwargs
        )
        assert capsys.readouterr().out == ""
    else:
        mock_sub._subprocess.Popen.assert_called_with(
            ["hello", "world"],
            start_new_session=start_new_session,
            **final_kwargs,
        )
        assert capsys.readouterr().out == ""