From: Joseph Sutton Date: Wed, 18 Oct 2023 01:15:27 +0000 (+1300) Subject: tests/krb5: Move assignments closer to where the variables are used X-Git-Tag: talloc-2.4.2~1221 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2ddd8ca3c72f0313452d6e89a2ccf1332b38f8ef;p=thirdparty%2Fsamba.git tests/krb5: Move assignments closer to where the variables are used Signed-off-by: Joseph Sutton Reviewed-by: Andrew Bartlett --- diff --git a/python/samba/tests/krb5/conditional_ace_tests.py b/python/samba/tests/krb5/conditional_ace_tests.py index d3caa1b0300..e294fbd41d9 100755 --- a/python/samba/tests/krb5/conditional_ace_tests.py +++ b/python/samba/tests/krb5/conditional_ace_tests.py @@ -2741,9 +2741,6 @@ class ConditionalAceTests(ConditionalAceBaseTests): except TypeError: self.assertIsNot(code, CRASHES_WINDOWS) - samdb = self.get_samdb() - domain_sid_str = samdb.get_domain_sid() - client_creds = self.get_cached_creds( account_type=self.AccountType.USER, opts={ @@ -2824,6 +2821,9 @@ class ConditionalAceTests(ConditionalAceBaseTests): target_creds) target_etypes = target_creds.tgs_supported_enctypes + samdb = self.get_samdb() + domain_sid_str = samdb.get_domain_sid() + expected_groups = self.map_sids(expected_groups, None, domain_sid_str) expected_device_groups = self.map_sids(expected_device_groups, None, domain_sid_str)