MCPcopy
hub / github.com/django/django / test_jsonb_agg

Method test_jsonb_agg

tests/postgres_tests/test_aggregates.py:357–359  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

355 self.assertEqual(values, {"arrayagg": [0, 1, 0, 2]})
356
357 def test_jsonb_agg(self):
358 values = AggregateTestModel.objects.aggregate(jsonbagg=JSONBAgg("char_field"))
359 self.assertEqual(values, {"jsonbagg": ["Foo1", "Foo2", "Foo4", "Foo3"]})
360
361 def test_jsonb_agg_charfield_order_by(self):
362 order_by_test_cases = (

Callers

nothing calls this directly

Calls 2

JSONBAggClass · 0.90
aggregateMethod · 0.80

Tested by

no test coverage detected