#NEWLINE# def test_iam_full_admin_list( self ) : #NEWLINE# #INDENT# import json #NEWLINE# from security_monkey.auditors.iam.iam_policy import IAMPolicyAuditor #NEWLINE# auditor = IAMPolicyAuditor ( accounts = [ 'unittest' ] ) #NEWLINE# iamobj = MockIAMObj ( ) #NEWLINE# iamobj . config = { #NEWLINE# #INDENT# 'userpolicies' : json . loads ( FULL_ADMIN_POLICY_LIST ) , #NEWLINE# #UNINDENT# } #NEWLINE# self . assertIs ( len ( iamobj . audit_issues ) , 0 , 'Policy should have 0 alert but has {}' . format ( len ( iamobj . audit_issues ) ) ) #NEWLINE# auditor . library_check_iamobj_has_star_privileges ( iamobj , multiple_policies = False ) #NEWLINE# self . assertIs ( len ( iamobj . audit_issues ) , 1 , 'Policy should have 1 alert but has {}' . format ( len ( iamobj . audit_issues ) ) )