1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

dsdb-tests: Give more helpful information about attribute differences

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
This commit is contained in:
Andrew Bartlett 2015-03-19 18:35:05 +13:00 committed by Michael Adam
parent 4f4151ea05
commit d3b208c1fc

View File

@ -83,7 +83,9 @@ class RestoredObjectAttributesBaseTestCase(samba.tests.TestCase):
return self.search_dn(msg['dn'])
def assertAttributesEqual(self, obj_orig, attrs_orig, obj_restored, attrs_rest):
self.assertEqual(attrs_orig, attrs_rest, "Actual object does not have expected attributes")
self.assertEqual(attrs_orig, attrs_rest,
"Actual object does not have expected attributes, missing from expected (%s), extra (%s)"
% (str(attrs_orig.difference(attrs_rest)), str(attrs_rest.difference(attrs_orig))))
# remove volatile attributes, they can't be equal
attrs_orig -= set(["uSNChanged", "dSCorePropagationData", "whenChanged"])
for attr in attrs_orig: