OPSI.ldaptor.test.test_schema module

Test cases for ldaptor.schema module.

class OPSI.ldaptor.test.test_schema.AttributeType_KnownValues(methodName='runTest')

Bases: twisted.trial._asynctest.TestCase

knownValues = [("( 2.5.4.4 NAME ( 'sn' 'surname' )\n DESC 'RFC2256: last (family) name(s) for which the entity is known by'\n SUP name )", {'oid': '2.5.4.4', 'name': ('sn', 'surname'), 'sup': 'name', 'desc': 'RFC2256: last (family) name(s) for which the entity is known by'}), ("( 2.5.4.2 NAME 'knowledgeInformation'\n DESC 'RFC2256: knowledge information'\n EQUALITY caseIgnoreMatch\n SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{32768} )", {'syntax': '1.3.6.1.4.1.1466.115.121.1.15{32768}', 'oid': '2.5.4.2', 'equality': 'caseIgnoreMatch', 'name': ('knowledgeInformation',), 'desc': 'RFC2256: knowledge information'}), ("( 2.5.4.5 NAME 'serialNumber'\n DESC 'RFC2256: serial number of the entity'\n EQUALITY caseIgnoreMatch\n\tSUBSTR caseIgnoreSubstringsMatch\n\tSYNTAX 1.3.6.1.4.1.1466.115.121.1.44{64} )", {'equality': 'caseIgnoreMatch', 'name': ('serialNumber',), 'oid': '2.5.4.5', 'syntax': '1.3.6.1.4.1.1466.115.121.1.44{64}', 'substr': 'caseIgnoreSubstringsMatch', 'desc': 'RFC2256: serial number of the entity'}), ("( 2.5.4.6 NAME ( 'c' 'countryName' )\n\tDESC 'RFC2256: ISO-3166 country 2-letter code'\n\tSUP name SINGLE-VALUE )", {'oid': '2.5.4.6', 'single_value': 1, 'name': ('c', 'countryName'), 'sup': 'name', 'desc': 'RFC2256: ISO-3166 country 2-letter code'}), ("( 1.2.840.113549.1.9.1\n\tNAME ( 'email' 'emailAddress' 'pkcs9email' )\n\tDESC 'RFC2459: legacy attribute for email addresses in DNs'\n\tEQUALITY caseIgnoreIA5Match\n\tSUBSTR caseIgnoreIA5SubstringsMatch\n\tSYNTAX 1.3.6.1.4.1.1466.115.121.1.26{128} )", {'equality': 'caseIgnoreIA5Match', 'name': ('email', 'emailAddress', 'pkcs9email'), 'oid': '1.2.840.113549.1.9.1', 'syntax': '1.3.6.1.4.1.1466.115.121.1.26{128}', 'substr': 'caseIgnoreIA5SubstringsMatch', 'desc': 'RFC2459: legacy attribute for email addresses in DNs'})]
testParse()
testStringification()
class OPSI.ldaptor.test.test_schema.ObjectClass_KnownValues(methodName='runTest')

Bases: twisted.trial._asynctest.TestCase

knownValues = [("( 2.5.6.4 NAME 'organization'\n\tDESC 'RFC2256: an organization'\n\tSUP top STRUCTURAL\n\tMUST o\n\tMAY ( userPassword $ searchGuide $ seeAlso $ businessCategory $\n\t\tx121Address $ registeredAddress $ destinationIndicator $\n\t\tpreferredDeliveryMethod $ telexNumber $ teletexTerminalIdentifier $\n\t\ttelephoneNumber $ internationaliSDNNumber $\n\t\tfacsimileTelephoneNumber $ street $ postOfficeBox $ postalCode $\n\t\tpostalAddress $ physicalDeliveryOfficeName $ st $ l $ description ) )", {'name': ('organization',), 'may': ['userPassword', 'searchGuide', 'seeAlso', 'businessCategory', 'x121Address', 'registeredAddress', 'destinationIndicator', 'preferredDeliveryMethod', 'telexNumber', 'teletexTerminalIdentifier', 'telephoneNumber', 'internationaliSDNNumber', 'facsimileTelephoneNumber', 'street', 'postOfficeBox', 'postalCode', 'postalAddress', 'physicalDeliveryOfficeName', 'st', 'l', 'description'], 'oid': '2.5.6.4', 'sup': ['top'], 'desc': 'RFC2256: an organization', 'type': 'STRUCTURAL', 'must': ['o']}), ("( 2.5.6.5 NAME 'organizationalUnit'\n\tDESC 'RFC2256: an organizational unit'\n\tSUP top STRUCTURAL\n\tMUST ou\n\tMAY ( userPassword $ searchGuide $ seeAlso $ businessCategory $\n\t\tx121Address $ registeredAddress $ destinationIndicator $\n\t\tpreferredDeliveryMethod $ telexNumber $ teletexTerminalIdentifier $\n\t\ttelephoneNumber $ internationaliSDNNumber $\n\t\tfacsimileTelephoneNumber $ street $ postOfficeBox $ postalCode $\n\t\tpostalAddress $ physicalDeliveryOfficeName $ st $ l $ description ) )", {'name': ('organizationalUnit',), 'may': ['userPassword', 'searchGuide', 'seeAlso', 'businessCategory', 'x121Address', 'registeredAddress', 'destinationIndicator', 'preferredDeliveryMethod', 'telexNumber', 'teletexTerminalIdentifier', 'telephoneNumber', 'internationaliSDNNumber', 'facsimileTelephoneNumber', 'street', 'postOfficeBox', 'postalCode', 'postalAddress', 'physicalDeliveryOfficeName', 'st', 'l', 'description'], 'oid': '2.5.6.5', 'sup': ['top'], 'desc': 'RFC2256: an organizational unit', 'type': 'STRUCTURAL', 'must': ['ou']})]
testParse()
testStringification()
class OPSI.ldaptor.test.test_schema.TestComparison(methodName='runTest')

Bases: twisted.trial._asynctest.TestCase

ORDER = ['country', 'organization', 'organizationalUnit']
setUp()
test_eq()
test_ne()
test_order()