'Binding information provided, host not connected to any segment'

def test_port_create_on_unconnected_host(self):

    (network, segment, _subnet) = self._create_test_segment_with_subnet()
    response = self._create_port(self.fmt, net_id=network['network']['id'], tenant_id=network['network']['tenant_id'], arg_list=(portbindings.HOST_ID,), **{portbindings.HOST_ID: 'fakehost'})
    res = self.deserialize(self.fmt, response)
    self.assertEqual(webob.exc.HTTPConflict.code, response.status_int)
    self.assertEqual(segment_exc.HostNotConnectedToAnySegment.__name__, res['NeutronError']['type'])
    self._setup_host_mappings([(segment['segment']['id'], 'otherhost')])
    response = self._create_port(self.fmt, net_id=network['network']['id'], tenant_id=network['network']['tenant_id'], arg_list=(portbindings.HOST_ID,), **{portbindings.HOST_ID: 'fakehost'})
    res = self.deserialize(self.fmt, response)
    self.assertEqual(webob.exc.HTTPConflict.code, response.status_int)
    self.assertEqual(segment_exc.HostNotConnectedToAnySegment.__name__, res['NeutronError']['type'])
