#NEWLINE# def test_notif_manager_list_types( self ) : #NEWLINE# #INDENT# clt = self . client #NEWLINE# mgr = clt . _notification_manager #NEWLINE# id_ = utils . random_unicode ( ) #NEWLINE# ret_body = { #NEWLINE# #INDENT# 'values' : [ { #NEWLINE# #INDENT# 'id' : id_ , #NEWLINE# #UNINDENT# } ] , #NEWLINE# #UNINDENT# } #NEWLINE# mgr . api . method_get = Mock ( return_value = ( None , ret_body ) ) #NEWLINE# ret = mgr . list_types ( ) #NEWLINE# mgr . api . method_get . assert_called_once_with ( '/notification_types' ) #NEWLINE# self . assertEqual ( len ( ret ) , 1 ) #NEWLINE# inst = ret [ 0 ] #NEWLINE# self . assertTrue ( isinstance ( inst , CloudMonitorNotificationType ) ) #NEWLINE# self . assertEqual ( inst . id , id_ )