source/projects/tentacles/test/python/test_store.py

20 lines
350 B
Python
Raw Normal View History

2023-06-03 19:22:49 +00:00
#!/usr/bin/env python3
from tentacles.store import Store
def test_store_initializes(store: Store):
assert isinstance(store, Store)
def test_store_savepoint(store: Store):
obj = store.savepoint()
assert hasattr(obj, "__enter__")
assert hasattr(obj, "__exit__")
flag = False
with obj:
flag = True
assert flag