diff --git a/tests/authentication_tests/test_user.py b/tests/authentication_tests/test_user.py index 8ea0eea7e0..7538355ade 100644 --- a/tests/authentication_tests/test_user.py +++ b/tests/authentication_tests/test_user.py @@ -51,6 +51,18 @@ def _create_script_user(self): api_script="api_script", api_key="api_key", http_proxy="http_proxy", + sudo_as_login=None, + ) + ) + + def _create_script_sudo_as_login_user(self): + return user.ShotgunUser( + user_impl.ScriptUser( + host="host", + api_script="api_script", + api_key="api_key", + http_proxy="http_proxy", + sudo_as_login="sudo_as_login", ) ) @@ -96,6 +108,11 @@ def test_login_value(self): script_user = self._create_script_user() self.assertIsNone(script_user.login) + sudo_user = self._create_script_sudo_as_login_user() + self.assertEqual(sudo_user.login, "sudo_as_login") + self.assertEqual(sudo_user.sudo_as_login, "sudo_as_login") + + class CustomUser(user_impl.ShotgunUserImpl): def __init__(self): super(CustomUser, self).__init__("https://test.shotgunstudio.com", None)