# Path: opennsa/nsa.py
# LOG_SYSTEM = 'opennsa.nsa'
# URN_UUID_PREFIX = 'urn:uuid:'
# BIDIRECTIONAL   = 'Bidirectional'
# class NSIHeader(object):
# class SecurityAttribute(object):
# class EmptyLabelSet(Exception):
# class Label(object):
# class STP(object): # Service Termination Point
# class Link(object):
# class Path(object):
# class NetworkServiceAgent(object):
# class ConnectionInfo(object):
# class Criteria(object):
# class QueryCriteria(Criteria):
# class Schedule(object):
# class Point2PointService(object):
#     def __init__(self, requester_nsa, provider_nsa, correlation_id=None, reply_to=None, security_attributes=None, connection_trace=None):
#     def _createCorrelationId(self):
#     def newCorrelationId(self):
#     def __repr__(self):
#     def __init__(self, type_, value):
#     def __repr__(self):
#     def __init__(self, type_, values=None):
#     def _parseLabelValues(self, values):
#         def createValue(value):
#     def intersect(self, other):
#     def labelValue(self):
#     def singleValue(self):
#     def enumerateValues(self):
#     def randomLabel(self):
#     def canMatch(l1, l2):
#     def __eq__(self, other):
#     def __repr__(self):
#     def __init__(self, network, port, label=None):
#     def shortName(self):
#     def baseURN(self):
#     def urn(self):
#     def __eq__(self, other):
#     def __repr__(self):
#     def __init__(self, src_stp, dst_stp):
#     def sourceSTP(self):
#     def destSTP(self):
#     def __eq__(self, other):
#     def __repr__(self):
#     def __init__(self, network_links):
#     def links(self):
#     def sourceEndpoint(self):
#     def destEndpoint(self):
#     def __str__(self):
#     def __init__(self, identity, endpoint, service_type=None):
#     def getHostPort(self):
#     def urn(self):
#     def getServiceType(self):
#     def __str__(self):
#     def __init__(self, connection_id, global_reservation_id, description, service_type, criterias, provider_nsa, requester_nsa, states, notification_id, result_id):
#     def __init__(self, revision, schedule, service_def):
#     def __init__(self, revision, schedule, service_def, children=None):
#     def __init__(self, start_time, end_time):
#     def __str__(self):
#     def __init__(self, source_stp, dest_stp, capacity, directionality=BIDIRECTIONAL, symmetric=False, ero=None, parameters=None):
# 
# Path: opennsa/plugins/pruner.py
# NETWORKS = []
# def pruneLabels(path):
#     def prunePaths(self, paths):
# class PrunerPlugin(BasePlugin):


from twisted.trial import unittest
from opennsa import nsa
from opennsa.plugins import pruner




class PrunerTest(unittest.TestCase):

    # These test cases assume that the pruner has surfnet as a prune target

    def setUp(self):
        pruner.NETWORKS = [ 'surfnet.nl' ]


    def testPruningStart(self):


# Path: opennsa/nsa.py
# LOG_SYSTEM = 'opennsa.nsa'
# URN_UUID_PREFIX = 'urn:uuid:'
# BIDIRECTIONAL   = 'Bidirectional'
# class NSIHeader(object):
# class SecurityAttribute(object):
# class EmptyLabelSet(Exception):
# class Label(object):
# class STP(object): # Service Termination Point
# class Link(object):
# class Path(object):
# class NetworkServiceAgent(object):
# class ConnectionInfo(object):
# class Criteria(object):
# class QueryCriteria(Criteria):
# class Schedule(object):
# class Point2PointService(object):
#     def __init__(self, requester_nsa, provider_nsa, correlation_id=None, reply_to=None, security_attributes=None, connection_trace=None):
#     def _createCorrelationId(self):
#     def newCorrelationId(self):
#     def __repr__(self):
#     def __init__(self, type_, value):
#     def __repr__(self):
#     def __init__(self, type_, values=None):
#     def _parseLabelValues(self, values):
#         def createValue(value):
#     def intersect(self, other):
#     def labelValue(self):
#     def singleValue(self):
#     def enumerateValues(self):
#     def randomLabel(self):
#     def canMatch(l1, l2):
#     def __eq__(self, other):
#     def __repr__(self):
#     def __init__(self, network, port, label=None):
#     def shortName(self):
#     def baseURN(self):
#     def urn(self):
#     def __eq__(self, other):
#     def __repr__(self):
#     def __init__(self, src_stp, dst_stp):
#     def sourceSTP(self):
#     def destSTP(self):
#     def __eq__(self, other):
#     def __repr__(self):
#     def __init__(self, network_links):
#     def links(self):
#     def sourceEndpoint(self):
#     def destEndpoint(self):
#     def __str__(self):
#     def __init__(self, identity, endpoint, service_type=None):
#     def getHostPort(self):
#     def urn(self):
#     def getServiceType(self):
#     def __str__(self):
#     def __init__(self, connection_id, global_reservation_id, description, service_type, criterias, provider_nsa, requester_nsa, states, notification_id, result_id):
#     def __init__(self, revision, schedule, service_def):
#     def __init__(self, revision, schedule, service_def, children=None):
#     def __init__(self, start_time, end_time):
#     def __str__(self):
#     def __init__(self, source_stp, dest_stp, capacity, directionality=BIDIRECTIONAL, symmetric=False, ero=None, parameters=None):
# 
# Path: opennsa/plugins/pruner.py
# NETWORKS = []
# def pruneLabels(path):
#     def prunePaths(self, paths):
# class PrunerPlugin(BasePlugin):


# Path: test/test_pruner.py
from twisted.trial import unittest
from opennsa import nsa
from opennsa.plugins import pruner





class PrunerTest(unittest.TestCase):

    # These test cases assume that the pruner has surfnet as a prune target

    def setUp(self):
        pruner.NETWORKS = [ 'surfnet.nl' ]


    def testPruningStart(self):


        sfn_link = nsa.Link( nsa.STP('surfnet.nl:1990:production7', 'ps',         nsa.Label('vlan', '1784')),