From: Noel Power Date: Thu, 14 Jun 2018 16:12:30 +0000 (+0100) Subject: s4/torture/drs: port samba4.drs.delete_object test for py2/py3 X-Git-Tag: tdb-1.3.17~1586 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=72497e1f9dc9a4bb15e392325ada14359f3f86df;p=thirdparty%2Fsamba.git s4/torture/drs: port samba4.drs.delete_object test for py2/py3 Signed-off-by: Noel Power Reviewed-by: Andrew Bartlett --- diff --git a/source4/torture/drs/python/delete_object.py b/source4/torture/drs/python/delete_object.py index 5ccd8fd29b6..5d45462adc5 100644 --- a/source4/torture/drs/python/delete_object.py +++ b/source4/torture/drs/python/delete_object.py @@ -70,12 +70,12 @@ class DrsDeleteObjectTestCase(drs_base.DrsBaseTestCase): # Deleted Object base DN dodn = self._deleted_objects_dn(sam_ldb) # now check properties of the user - cn_orig = obj_orig["cn"][0] - cn_cur = user_cur["cn"][0] - name_orig = obj_orig["name"][0] - name_cur = user_cur["name"][0] + cn_orig = str(obj_orig["cn"][0]) + cn_cur = str(user_cur["cn"][0]) + name_orig = str(obj_orig["name"][0]) + name_cur = str(user_cur["name"][0]) if is_deleted: - self.assertEquals(user_cur["isDeleted"][0], "TRUE") + self.assertEquals(str(user_cur["isDeleted"][0]), "TRUE") self.assertFalse("objectCategory" in user_cur) self.assertFalse("sAMAccountType" in user_cur) self.assertFalse("description" in user_cur)