#NEWLINE# @ mock . patch . object ( trovebox . Trovebox , 'post' ) #NEWLINE# def test_album_add_id( self , mock_post ) : #NEWLINE# #INDENT# ' Check that photos can be added to an album using IDs ' #NEWLINE# mock_post . return_value = self . _return_value ( self . test_albums_dict [ 1 ] ) #NEWLINE# result = self . client . album . add ( self . test_albums [ 0 ] . id , objects = [ '1a' , '2b' ] , object_type = 'photo' , foo = 'bar' ) #NEWLINE# mock_post . assert_called_with ( '/album/1/photo/add.json' , ids = [ '1a' , '2b' ] , foo = 'bar' ) #NEWLINE# self . assertEqual ( result . id , self . test_albums [ 1 ] . id )