def test_post_new_profile(self):
        params = {"profileId": "prof:test_post_new_profile", "agent": self.testagent}
        path = '%s?%s' % (reverse('lrs:agent_profile'), urllib.urlencode(params))
        prof = {"test":"post new profile","obj":{"agent":"mailto:test@example.com"}}
        
        post = self.client.post(path, prof, content_type="application/json", Authorization=self.auth,  X_Experience_API_Version=settings.XAPI_VERSION)
        self.assertEqual(post.status_code, 204)
        
        get = self.client.get(path, Authorization=self.auth,  X_Experience_API_Version=settings.XAPI_VERSION)
        self.assertEqual(get.status_code, 200)
        self.assertEqual(ast.literal_eval(get.content), prof)
        self.assertEqual(get.get('etag'), '"%s"' % hashlib.sha1(get.content).hexdigest())
        self.client.delete(path, Authorization=self.auth,  X_Experience_API_Version=settings.XAPI_VERSION)
dataset/ETHPy150Open adlnet/ADL_LRS/lrs/tests/test_AgentProfile.py/AgentProfileTests.test_post_new_profile/original