diff --git a/resources/NBTest/NBTest_037_Exchanges.ipynb b/resources/NBTest/NBTest_037_Exchanges.ipynb index ebeca45c1..a635259b1 100644 --- a/resources/NBTest/NBTest_037_Exchanges.ipynb +++ b/resources/NBTest/NBTest_037_Exchanges.ipynb @@ -43,6 +43,9 @@ "import nest_asyncio\n", "nest_asyncio.apply()\n", "import pytest\n", + "import asyncio\n", + "from unittest.mock import AsyncMock\n", + "\n", "\n", "print(\"{0.__name__} v{0.__VERSION__} ({0.__DATE__})\".format(CPC))\n", "print(\"{0.__name__} v{0.__VERSION__} ({0.__DATE__})\".format(Bot))\n", @@ -91,7 +94,6 @@ }, "outputs": [], "source": [ - "from unittest.mock import AsyncMock\n", "\n", "mocked_contract = Mock()\n", "\n", @@ -155,7 +157,7 @@ }, "outputs": [], "source": [ - "import asyncio, pytest\n", + "\n", "\n", "uniswap_v2_exchange = UniswapV2()\n", "\n", diff --git a/resources/NBTest/NBTest_037_Exchanges.py b/resources/NBTest/NBTest_037_Exchanges.py index 479a4ebaa..1c12fb2a9 100644 --- a/resources/NBTest/NBTest_037_Exchanges.py +++ b/resources/NBTest/NBTest_037_Exchanges.py @@ -28,6 +28,9 @@ import nest_asyncio nest_asyncio.apply() import pytest +import asyncio +from unittest.mock import AsyncMock + print("{0.__name__} v{0.__VERSION__} ({0.__DATE__})".format(CPC)) print("{0.__name__} v{0.__VERSION__} ({0.__DATE__})".format(Bot)) @@ -52,7 +55,6 @@ setup_data = json.load(f) # + -from unittest.mock import AsyncMock mocked_contract = Mock() @@ -80,7 +82,7 @@ # ## test_uniswap_v2_exchange # + -import asyncio, pytest + uniswap_v2_exchange = UniswapV2()