def METHOD_NAME(aiida_localhost):
    """Test the constructor when it is supposed to raise."""
    with pytest.raises(TypeError, match=r'missing .* required positional arguments'):
        InstalledCode()  # pylint: disable=no-value-for-parameter
    with pytest.raises(TypeError, match=r'Got object of type .*'):
        InstalledCode(computer=aiida_localhost, filepath_executable=pathlib.Path('/usr/bin/bash'))
    with pytest.raises(TypeError, match=r'Got object of type .*'):
        InstalledCode(computer='computer', filepath_executable='/usr/bin/bash')