Skip to content

Commit 0ee6337

Browse files
authored
[TEST] rename _fork_enabled to _fork_table_enabled (#186)
For fork table test cases, it calls _fork_enabled originally, now renamed to _fork_table_enabled <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Tests** * Updated fork-related test infrastructure to align with server-side capability checks. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent 8a68b6c commit 0ee6337

1 file changed

Lines changed: 11 additions & 11 deletions

File tree

tests/integration_tests/test_collection_fork.py

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323
class TestCollectionFork:
2424
"""Tests for collection.fork() method using real database connections."""
2525

26-
def _is_fork_enabled(self, client) -> bool:
26+
def _is_fork_table_enabled(self, client) -> bool:
2727
"""Check if fork is enabled for the given client."""
2828
try:
29-
return client._server._fork_enabled()
29+
return client._server._fork_table_enabled()
3030
except Exception:
3131
logger.exception("Failed to check if fork is enabled")
3232
return False
@@ -39,7 +39,7 @@ def test_fork_success(self, db_client):
3939
Skips if fork is not enabled for the database.
4040
"""
4141
# Check if fork is enabled
42-
if not self._is_fork_enabled(db_client):
42+
if not self._is_fork_table_enabled(db_client):
4343
pytest.skip("Fork is not enabled for this database")
4444

4545
# Create test collection
@@ -101,7 +101,7 @@ def test_fork_with_invalid_name(self, db_client):
101101
Skips if fork is not enabled for the database.
102102
"""
103103
# Check if fork is enabled
104-
if not self._is_fork_enabled(db_client):
104+
if not self._is_fork_table_enabled(db_client):
105105
pytest.skip("Fork is not enabled for this database")
106106

107107
# Create test collection
@@ -130,7 +130,7 @@ def test_fork_with_empty_name(self, db_client):
130130
Skips if fork is not enabled for the database.
131131
"""
132132
# Check if fork is enabled
133-
if not self._is_fork_enabled(db_client):
133+
if not self._is_fork_table_enabled(db_client):
134134
pytest.skip("Fork is not enabled for this database")
135135

136136
# Create test collection
@@ -159,7 +159,7 @@ def test_fork_preserves_original_collection(self, db_client):
159159
Skips if fork is not enabled for the database.
160160
"""
161161
# Check if fork is enabled
162-
if not self._is_fork_enabled(db_client):
162+
if not self._is_fork_table_enabled(db_client):
163163
pytest.skip("Fork is not enabled for this database")
164164

165165
# Create test collection
@@ -214,7 +214,7 @@ def test_fork_independent_operations(self, db_client):
214214
Skips if fork is not enabled for the database.
215215
"""
216216
# Check if fork is enabled
217-
if not self._is_fork_enabled(db_client):
217+
if not self._is_fork_table_enabled(db_client):
218218
pytest.skip("Fork is not enabled for this database")
219219

220220
# Create test collection
@@ -278,7 +278,7 @@ def test_fork_v1_collection_success(self, db_client):
278278
Skips if fork is not enabled for the database.
279279
"""
280280
# Check if fork is enabled
281-
if not self._is_fork_enabled(db_client):
281+
if not self._is_fork_table_enabled(db_client):
282282
pytest.skip("Fork is not enabled for this database")
283283

284284
# Create v1 test collection
@@ -350,7 +350,7 @@ def test_fork_v1_collection_preserves_original(self, db_client):
350350
Skips if fork is not enabled for the database.
351351
"""
352352
# Check if fork is enabled
353-
if not self._is_fork_enabled(db_client):
353+
if not self._is_fork_table_enabled(db_client):
354354
pytest.skip("Fork is not enabled for this database")
355355

356356
# Create v1 test collection
@@ -412,7 +412,7 @@ def test_fork_v1_collection_independent_operations(self, db_client):
412412
Skips if fork is not enabled for the database.
413413
"""
414414
# Check if fork is enabled
415-
if not self._is_fork_enabled(db_client):
415+
if not self._is_fork_table_enabled(db_client):
416416
pytest.skip("Fork is not enabled for this database")
417417

418418
# Create v1 test collection
@@ -494,7 +494,7 @@ def test_fork_v1_and_v2_collections(self, db_client):
494494
Skips if fork is not enabled for the database.
495495
"""
496496
# Check if fork is enabled
497-
if not self._is_fork_enabled(db_client):
497+
if not self._is_fork_table_enabled(db_client):
498498
pytest.skip("Fork is not enabled for this database")
499499

500500
# Create both v1 and v2 collections

0 commit comments

Comments
 (0)