forked from LBRYCommunity/lbry-sdk
fix test_announces
This commit is contained in:
parent
ec0d9f06c5
commit
89ed04f8a7
1 changed files with 2 additions and 8 deletions
|
@ -107,18 +107,12 @@ class FileCommands(CommandTestCase):
|
||||||
self.assertEqual(await self.daemon.storage.get_blobs_to_announce(), [])
|
self.assertEqual(await self.daemon.storage.get_blobs_to_announce(), [])
|
||||||
await self.stream_create('foo', '0.01')
|
await self.stream_create('foo', '0.01')
|
||||||
stream = (await self.daemon.jsonrpc_file_list())["items"][0]
|
stream = (await self.daemon.jsonrpc_file_list())["items"][0]
|
||||||
self.assertSetEqual(
|
self.assertSetEqual(set(await self.daemon.storage.get_blobs_to_announce()), {stream.sd_hash})
|
||||||
set(await self.daemon.storage.get_blobs_to_announce()),
|
|
||||||
{stream.sd_hash, stream.descriptor.blobs[0].blob_hash}
|
|
||||||
)
|
|
||||||
self.assertTrue(await self.daemon.jsonrpc_file_delete(delete_all=True))
|
self.assertTrue(await self.daemon.jsonrpc_file_delete(delete_all=True))
|
||||||
# announces on download
|
# announces on download
|
||||||
self.assertEqual(await self.daemon.storage.get_blobs_to_announce(), [])
|
self.assertEqual(await self.daemon.storage.get_blobs_to_announce(), [])
|
||||||
stream = await self.daemon.jsonrpc_get('foo')
|
stream = await self.daemon.jsonrpc_get('foo')
|
||||||
self.assertSetEqual(
|
self.assertSetEqual(set(await self.daemon.storage.get_blobs_to_announce()), {stream.sd_hash})
|
||||||
set(await self.daemon.storage.get_blobs_to_announce()),
|
|
||||||
{stream.sd_hash, stream.descriptor.blobs[0].blob_hash}
|
|
||||||
)
|
|
||||||
|
|
||||||
async def _purge_file(self, claim_name, full_path):
|
async def _purge_file(self, claim_name, full_path):
|
||||||
self.assertTrue(
|
self.assertTrue(
|
||||||
|
|
Loading…
Reference in a new issue