Skip to content

Commit aec60d2

Browse files
committed
PYTHON-4834 Add __repr__ to IndexModel
- Review fixes
1 parent d0c7499 commit aec60d2

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

test/test_operations.py

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,7 @@
2121

2222

2323
class TestOperations(UnitTest):
24-
"""Test Operations module including methods:
25-
_Op, _DeleteOp, _UpdateOp,
26-
DeleteOne, DeleteMany,
27-
InsertOne,
28-
ReplaceOne,
29-
UpdateOne, UpdateMany,
30-
IndexModel,
31-
SearchIndexModel"""
24+
"""Test the operations module."""
3225

3326
def test_index_model_repr(self):
3427
# Based on examples in test_collection.py
@@ -37,7 +30,6 @@ def test_index_model_repr(self):
3730
self.assertRepr(
3831
IndexModel([("hello", DESCENDING), ("world", ASCENDING)], name="hello_world")
3932
)
40-
4133
# Test all the kwargs
4234
self.assertRepr(IndexModel("name", name="name"))
4335
self.assertRepr(IndexModel("unique", unique=False))
@@ -53,7 +45,6 @@ def test_index_model_repr(self):
5345
self.assertRepr(IndexModel("collation", collation=Collation(locale="en_US")))
5446
self.assertRepr(IndexModel("wildcardProjection", wildcardProjection={"$**": 1}))
5547
self.assertRepr(IndexModel("hidden", hidden=False))
56-
5748
# Test string literal
5849
self.assertEqual(repr(IndexModel("hello")), "IndexModel({'hello': 1}, name='hello_1')")
5950
self.assertEqual(

0 commit comments

Comments
 (0)