Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F7163758
D2091.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
D2091.id.diff
View Options
diff --git a/swh/storage/tests/test_storage.py b/swh/storage/tests/test_storage.py
--- a/swh/storage/tests/test_storage.py
+++ b/swh/storage/tests/test_storage.py
@@ -22,34 +22,11 @@
from swh.model import from_disk, identifiers
from swh.model.hashutil import hash_to_bytes
from swh.model.hypothesis_strategies import objects
-from swh.storage.tests.storage_testing import StorageTestFixture
from swh.storage import HashCollision
from .storage_data import data
-@pytest.mark.db
-class StorageTestDbFixture(StorageTestFixture):
- def setUp(self):
- super().setUp()
- self.maxDiff = None
-
- def tearDown(self):
- self.reset_storage()
- if hasattr(self.storage, '_pool') and self.storage._pool:
- self.storage._pool.closeall()
- super().tearDown()
-
- def get_db(self):
- return self.storage.db()
-
- @contextmanager
- def db_transaction(self):
- with self.get_db() as db:
- with db.transaction() as cur:
- yield db, cur
-
-
@contextmanager
def db_transaction(storage):
with storage.db() as db:
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Jan 30, 2:47 PM (7 h, 37 m ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3220001
Attached To
D2091: test_storage: kill StorageTestDbFixture class
Event Timeline
Log In to Comment