def METHOD_NAME(inference_state, Script, environment):
    if isinstance(environment, InterpreterEnvironment):
        pytest.skip("We cannot kill our own process")
    # Just kill the subprocess.
    inference_state.compiled_subprocess._compiled_subprocess._get_process().kill()
    # Since the process was terminated (and nobody knows about it) the first
    # Jedi call fails.
    with pytest.raises(jedi.InternalError):
        Script('str').infer()
    def_, = Script('str').infer()
    # Jedi should now work again.
    assert def_.name == 'str'