mirror of
https://github.com/samba-team/samba.git
synced 2025-01-08 21:18:16 +03:00
python:tests: Simplify expression
‘not keytab_bytes’ is shorter and equivalent. Signed-off-by: Jo Sutton <josutton@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
86db305617
commit
398a555fc2
@ -76,7 +76,7 @@ class DCKeytabTests(TestCaseInTempDir):
|
||||
keytab_as_set.add(entry_as_tuple)
|
||||
|
||||
keytab_bytes = multiple_entry.further_entry
|
||||
if keytab_bytes is None or len(keytab_bytes) == 0:
|
||||
if not keytab_bytes:
|
||||
break
|
||||
|
||||
return keytab_as_set
|
||||
@ -433,7 +433,7 @@ class DCKeytabTests(TestCaseInTempDir):
|
||||
while True:
|
||||
local_keys[local_keytab.entry.enctype] = local_keytab.entry.key.data
|
||||
keytab_bytes = local_keytab.further_entry
|
||||
if keytab_bytes is None or len(keytab_bytes) == 0:
|
||||
if not keytab_bytes:
|
||||
break
|
||||
local_keytab = ndr_unpack(krb5ccache.MULTIPLE_KEYTAB_ENTRIES, keytab_bytes)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user