Skip to content

Commit

Permalink
fix test async dictstorage
Browse files Browse the repository at this point in the history
  • Loading branch information
guangrei committed Oct 13, 2024
1 parent 53a78b1 commit 9a50a81
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Tests/test_async_dicstorage.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@

class DBTest(IsolatedAsyncioTestCase):

async def test_database_or_cache(self):
c = await AsyncDatabase("/tmp/async_dicstorage_test.json", storage=AsyncDictStorage)
async def test_database_or_cache(self) -> None:
storage = AsyncDictStorage("test")
await storage.init()
c = AsyncDatabase(storage=storage)
await c.init()
await c.reset()

expected = await c.set("foo", "bar")
self.assertEqual(expected, True)
self.assertEqual(expected, True)

0 comments on commit 9a50a81

Please sign in to comment.