def test_update_node_associate_and_disassociate(self):
    node = utils.create_test_node()
    new_i_uuid = uuidutils.generate_uuid()
    res = self.dbapi.update_node(node.id, {'instance_uuid': new_i_uuid})
    self.assertEqual(new_i_uuid, res.instance_uuid)
    res = self.dbapi.update_node(node.id, {'instance_uuid': None})
    self.assertIsNone(res.instance_uuid)
def test_update_node_associate_and_disassociate(self):
    node = utils.create_test_node()
    new_i_uuid = uuidutils.generate_uuid()
    res = self.dbapi.update_node(node.id, {'instance_uuid': new_i_uuid})
    self.assertEqual(new_i_uuid, res.instance_uuid)
    res = self.dbapi.update_node(node.id, {'instance_uuid': None})
    self.assertIsNone(res.instance_uuid)