We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9284b1f commit 42b2562Copy full SHA for 42b2562
tests/mql_panel/test_forms.py
@@ -31,11 +31,11 @@ def test_simple_fields(self):
31
32
def test_objectid(self):
33
"""MongoDB ObjectId from a document."""
34
- oid = ObjectId()
+ oid = "69cd52da72ad0703d3dfef51"
35
result = self.form._format_cell_value(oid)
36
# ObjectIds serialize to {"$oid": "<id>"} which is single-key
37
self.assertIs(result["is_json"], False)
38
- self.assertEqual(result["value"], str(json.loads(json_util.dumps(oid))["$oid"]))
+ self.assertEqual(result["value"], oid)
39
40
def test_datetime(self):
41
"""Datetime values as they might appear in a MongoDB doc."""
0 commit comments