def test_get_conj_id(self):
    allocated = []
    for direction in [firewall.EGRESS_DIRECTION, firewall.INGRESS_DIRECTION]:
        id_ = self.conj_id_map.get_conj_id('sg', 'remote', direction, constants.IPv4)
        allocated.append(id_)
    self.assertEqual(len(set(allocated)), 2)
    self.assertEqual(len(self.conj_id_map.id_map), 2)
    self.assertEqual(self.conj_id_map.get_conj_id('sg', 'remote', firewall.EGRESS_DIRECTION, constants.IPv4), allocated[0])
def test_get_conj_id(self):
    allocated = []
    for direction in [firewall.EGRESS_DIRECTION, firewall.INGRESS_DIRECTION]:
        id_ = self.conj_id_map.get_conj_id('sg', 'remote', direction, constants.IPv4)
        allocated.append(id_)
    self.assertEqual(len(set(allocated)), 2)
    self.assertEqual(len(self.conj_id_map.id_map), 2)
    self.assertEqual(self.conj_id_map.get_conj_id('sg', 'remote', firewall.EGRESS_DIRECTION, constants.IPv4), allocated[0])