diff --git a/pyperformance/data-files/benchmarks/bm_asyncio_websockets/run_benchmark.py b/pyperformance/data-files/benchmarks/bm_asyncio_websockets/run_benchmark.py index 577ba813..1f167f6f 100644 --- a/pyperformance/data-files/benchmarks/bm_asyncio_websockets/run_benchmark.py +++ b/pyperformance/data-files/benchmarks/bm_asyncio_websockets/run_benchmark.py @@ -1,6 +1,8 @@ """ Benchmark for asyncio websocket server and client performance -transferring 10MB of data. +transferring 1MB of data. + +Author: Kumar Aditya """ import pyperf @@ -8,7 +10,7 @@ import websockets.client import asyncio -CHUNK_SIZE = 1024 +CHUNK_SIZE = 1024 ** 2 DATA = b"x" * CHUNK_SIZE stop: asyncio.Event @@ -16,8 +18,7 @@ async def handler(websocket) -> None: for _ in range(100): - data = await websocket.recv() - assert data == DATA + await websocket.recv() stop.set()