def test_port_init(self): port_dict = apiutils.port_post_data(node_id=None) del port_dict['extra'] port = api_port.Port(**port_dict) self.assertEqual(wtypes.Unset, port.extra)
def post_get_test_port(**kw): port = apiutils.port_post_data(**kw) node = dbutils.get_test_node() port['node_uuid'] = kw.get('node_uuid', node['uuid']) return port