def METHOD_NAME(instance):
    instance['connection_name'] = "localhost(8080)"
    del instance['host']
    del instance['port']
    instance['override_hostname'] = True
    with pytest.raises(
        ConfigurationError,
        match="You cannot override the hostname if you provide a `connection_name` instead of a `host`",
    ):
        IBMMQConfig(instance, {})