11asyncodbc
22=========
3- .. image :: https://travis-ci .com/tortoise/asyncodbc.svg?branch=main
4- :target: https://travis-ci .com/tortoise/asyncodbc
3+ .. image :: https://github .com/tortoise/asyncodbc/actions/workflows/ci.yml/badge .svg?branch=main
4+ :target: https://github .com/tortoise/asyncodbc/actions?query=workflow:ci
55.. image :: https://coveralls.io/repos/tortoise/asyncodbc/badge.svg?branch=main&service=github
66 :target: https://coveralls.io/github/tortoise/asyncodbc?branch=main
77.. image :: https://img.shields.io/pypi/v/asyncodbc.svg
@@ -40,9 +40,6 @@ Properties are unchanged, so ``conn.prop`` is correct as well as
4040 import asyncodbc
4141
4242
43- loop = asyncio.get_event_loop()
44-
45-
4643 async def test_example ():
4744 dsn = ' Driver=SQLite;Database=sqlite.db'
4845 conn = await asyncodbc.connect(dsn = dsn, loop = loop)
@@ -56,7 +53,7 @@ Properties are unchanged, so ``conn.prop`` is correct as well as
5653 await cur.close()
5754 await conn.close()
5855
59- loop.run_until_complete (test_example())
56+ asyncio.run (test_example())
6057
6158
6259 Connection Pool
@@ -69,9 +66,6 @@ Connection pooling is ported from aiopg_ and relies on PEP492_ features:
6966 import asyncodbc
7067
7168
72- loop = asyncio.get_event_loop()
73-
74-
7569 async def test_pool ():
7670 dsn = ' Driver=SQLite;Database=sqlite.db'
7771 pool = await asyncodbc.create_pool(dsn = dsn, loop = loop)
@@ -86,7 +80,7 @@ Connection pooling is ported from aiopg_ and relies on PEP492_ features:
8680 pool.close()
8781 await pool.wait_closed()
8882
89- loop.run_until_complete (test_pool())
83+ asyncio.run (test_pool())
9084
9185
9286 Context Managers
@@ -100,9 +94,6 @@ protocol:
10094 import asyncodbc
10195
10296
103- loop = asyncio.get_event_loop()
104-
105-
10697 async def test_example ():
10798 dsn = ' Driver=SQLite;Database=sqlite.db'
10899
@@ -114,7 +105,7 @@ protocol:
114105 print (val)
115106 print (val.age)
116107
117- loop.run_until_complete (test_example())
108+ asyncio.run (test_example())
118109
119110
120111 Installation
@@ -134,21 +125,13 @@ then::
134125Run tests
135126---------
136127
137- For testing purposes you need to install docker _ and the development
138- requirements::
128+ For testing purposes you need to install the test group requirements::
139129
140- $ pip install -r pyproject.toml --group test -e .
141-
142- In order to simplify development you should install the provided docker container.
143- This way you don't need to install any databases or other system libraries, everything happens inside the container.
130+ $ uv pip install -r pyproject.toml --group test -e .
144131
145132Then just execute::
146133
147- $ make docker_build
148- $ make docker_test
149-
150- The test will automatically pull images and build containers with
151- the required databases.
134+ $ make test_mssql
152135
153136*NOTE: * Running tests requires Python 3.9 or higher.
154137
0 commit comments