

def test_basic(self):
    ds = UserDataSource({
        
    }, keys=[['user1'], ['user2']], group_by=['user'])
    data = ds.get_data()
    self.assertItemsEqual(data, [{
        'user': 'Bob',
        'indicator_a': 1,
        'indicator_b': 1,
        'cd': 50,
    }, {
        'user': 'Joe',
        'indicator_a': 1,
        'indicator_b': 1,
        'cd': 100,
    }])

dataset/ETHPy150Open dimagi/commcare-hq/corehq/apps/reports/tests/test_report_api.py ReportAPITest.test_basic/original