def test_start(self, mocked_proxy): mocked_proxy = mocked_proxy() mocked_proxy.d.start.return_value = 0 client = RTorrent('http://localhost/RPC2') resp = client.start(torrent_info_hash) assert resp == 0 assert mocked_proxy.d.start.called_with((torrent_info_hash,))