Skip to content

Commit 1f50ad6

Browse files
committed
Add test case for ldap.dn.str2dn(…, flags=ldap.DN_FORMAT_DCE)
1 parent 893bd27 commit 1f50ad6

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Tests/t_ldap_dn.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,15 @@ def test_str2dn(self):
118118
[('dc', 'com', 1)]
119119
]
120120
)
121+
self.assertEqual(
122+
ldap.dn.str2dn('/dc=com/dc=example/ou=Testing/uid=test42', flags=ldap.DN_FORMAT_DCE),
123+
[
124+
[('uid', 'test42', 1)],
125+
[('ou', 'Testing', 1)],
126+
[('dc', 'example', 1)],
127+
[('dc', 'com', 1)]
128+
]
129+
)
121130

122131
def test_dn2str(self):
123132
"""

0 commit comments

Comments
 (0)