#NEWLINE# def testSetsSettingsForUserCorrespondingToToken( self ) : #NEWLINE# #INDENT# settings = aff4_users . GUISettings ( mode = 'ADVANCED' , canary_mode = True , docs_location = 'REMOTE' ) #NEWLINE# result = self . handler . Render ( settings , token = access_control . ACLToken ( username = 'foo' ) ) #NEWLINE# self . assertEqual ( result [ 'status' ] , 'OK' ) #NEWLINE# fd = aff4 . FACTORY . Open ( 'aff4:/users/foo' , token = self . token ) #NEWLINE# self . assertEqual ( fd . Get ( fd . Schema . GUI_SETTINGS ) , settings )