'Testing whether the stop method in LibtorrentDownloadImpl invokes the correct method'

def test_stop(self):

    def mocked_stop_remove(removestate, removecontent):
        self.assertFalse(removestate)
        self.assertFalse(removecontent)
        mocked_stop_remove.called = True
    mocked_stop_remove.called = False
    self.libtorrent_download_impl.stop_remove = mocked_stop_remove
    self.libtorrent_download_impl.stop()
    self.assertTrue(mocked_stop_remove.called)
