def test__fetch_tracked_entity_attributes(self):
        te_attrs = {'trackedEntityAttributes': [
            {'name': 'ham', 'id': 'deadbeef'},
            {'name': 'spam', 'id': 'c0ffee'},
        ]}
        dhis2_api = Dhis2Api('http://example.com/dhis', 'user', 'p4ssw0rd')
        dhis2_api._request.get = Mock(return_value=te_attrs)
        keys_before = set(dhis2_api._tracked_entity_attributes.keys())
        dhis2_api._fetch_tracked_entity_attributes()
        keys_after = set(dhis2_api._tracked_entity_attributes.keys())
        fetched = keys_after - keys_before
        self.assertIn('ham', fetched)
        self.assertIn('spam', fetched)
add a training data point to a node in the tree
dataset/ETHPy150Open dimagi/commcare-hq/custom/dhis2/tests.py/Dhis2ApiTest.test__fetch_tracked_entity_attributes--crossover with--dataset/ETHPy150Open balajiln/mondrianforest/src/mondrianforest.py/MondrianTree.add_training_points_to_node